0
Answered

How do you create a new quote using the Home Portal API?

Mike MacKechnie 3 years ago in API updated by mark 2 years ago 19

I've searched the API documentation, and all the questions here, but I can't find an answer to the questions - how can I create a quote using the Home Portal API? I see lots of API's which can act on a known quote number, but what about if you have an incoming request which requires a quote to be created before the project can be created? We have a customer who has this requirement, and at the moment we are having to create projects via the API,  which we then "disguise" as quotes (basically by sticking the word Quote at the end of the project name).

If you are using Smart Projects you could use the POST method for creating quotes: https://simplytranslate.s.xtrf.eu/api/doc/users/pages/v2-quotes.html

Classic Projects doesn't seem to have the option of creating quotes.


If you use Classic Projects I think your way to go is by creating a macro that creates the Quote.

We ended up setting up zapier to get this done. I discussed this a bit on this thread. 


http://xtrf.userecho.com/forums/8-questions-answers/topics/653-please-share-an-experience-of-the-use-of-api/#


Not sure if that helps, but I'm happy to provide more information if you'd like.


It's far from perfect, but it generally works...


M

+1

Hi Mark,


I'd like to see what information you've got on this. I'm not crazy about the idea of adding another layer of third -party sofware to our portfolio, but if it automates the process and is relatively painless to implement, I'd be up for giving it a try.

+1

I'll do the best I can to share, but it's not ideal. And yes, I hired a developer to do this for me. Now I can manage it via Zapier, but I needed expertise to get it started.


As for painless, it all depends on your threshold for pain.


The short version is that Zapier allows you to create Web Builder Apps - essentially custom connectors. We connected our XTRF via the API and created a series of actions. Then, each action can be used as a connection between web services. FYI, we're not using it for creating new projects. Here are the actions that we created:


  • Create Customer 
  • Create Quote 
  • Create Person   
  • Update Customer 
  • Update Source Language in Quote 
  • Update Target Language in Quote   
  • Update Expected Delivery Date in Quote 
  • Update Internal Notes in Quote 
  • Update Customer Industries


Each action has specific fields associated with them, and then each can be added to a specific "Zap". We have four zaps created that we use based on the information provided in the initial web quote:


* Quote for a company with files

* Quote for a company without files

* Quote for an individual with files

* Quote for an individual without files

So, broadly speaking, there are four things that need to get done... 1) Connect XTRF to Zapier via  your API. 2) Create your actions. 3) Create your zaps 4) Connect to your website.


It's not for the faint of heart in my opinion. Starting from scratch, it was about a 20-30 hour project to get done and working. It would be very helpful if XTRF wanted to create zaps for people to use to simplify the connection process. :) But that's a conversation for another day.


I'm not sure how to export what we've done in Zapier, but I'll be happy to share settings or even share screen grabs if that would be helpful. 

We've also experimented with zapier and we use wordpress and gravity forms which has built in integrations with zapier.


The problem with Zapier as Mark says is that you have to have multiple "Zaps" to cover each variation. In our case it is:
New Company | New Contact - A company we have never worked for, and a contact we have never worked with (based on their company name/domain)
Existing Company | New Contact - A company we have worked with but a contact we have never worked with
New Private individual - a private individual we have never worked with

Existing private individual

Each zap starts with some tests called filters that check if the form submission matches the criteria, and if not, it ends the Zap without proceeding. The reason this is necessary is because even some of our established clients will just pop onto our site and use our really easy to use quote form. So we have to make sure we take account of this, because for new customers, we have to create a record in the system, but for existing ones, we have to look them up. Gets complicated thinking and testing all of the possible variations. And I didn't have a developer to help me, and the API docs are a bit lacking.


So why is this a problem? Simply because of Zapier's pricing structure: you get so many "tasks" a month with each plan.  A "task" is anytime a "Zap" is fired. So if you have to have 4 zaps to cover all of your possible occurences, then each time a form submits, you use 4 tasks, even though there was only one of those Zaps that actually matched. So filtered tasks still count against you.


I would suggest, if you are going to have a developer help you, that you look into Flow XO, which I am converting to now, or Microsoft Flow. Both of these are a bit harder to use, and don't have as many prebuilt integrations, but what they both have is branching logic. So instead of having to have 4 zaps and testing to see if a customer has files or doesn't have files, you can simply say "if has files, branch this way. If not, do this". Or in Flow XO, you can use labels so you can have one really long flow (same as a Zap) and put label markers and add logic that says "If this, then go to Label X" where the part of the workflow corresponding to a certain case starts at Label X. At the end of each workflow snippet, you put an "End" marker so it stops. For files, you can also have every workflow include a file step but just say if there are files, run the file upload step, and skip it if they don't. So all of those zaps turn into a single task (or interaction in Flow XO). For Flow XO, it's $19 a month for 5000 tasks/interactions and 15 active flows/zaps. That's 5x more than Zapier. Microsoft is pretty similar, so really Zapier is overly costly, though maybe a little simpler to setup.

I will have to look at Flow XO. I've never tried it. But yes, I have four zaps running for each instance. That also makes it a pain to trouble shoot. It's works, but it's a pain.

Indeed. I also have reservations about the security of these third-party solutions.

I have another questions about creating quotes via the API. Does anyone have experience with doing this? Our quotes via the API all have a default sales person as me. There doesn't seem to be an option to select the default salesperson. So, it's my account to which the API is connected. I'm assuming that because it's my account, that's why I'm also the sales person. So, if I want to change the sales person, that would imply that I need to set up an API connector using the sales person account. Does anyone have this experience? Am I barking up the right tree on this?

+1

We use the Quote Request Form a lot, as well as the API where we add quotes. Because the Quote Request Form can only have one person as default Sales Person, we had to figure out a way to assign this. And as we figured it out, it also provided a solution for creating the quotes through the API.

We have a subscription when the quotes are created.

After this subsciption is trigged by the creation of one quote we automatically trigger a macro with the specific quote.

The macro determines who the sales person should be and assigns it.


This should work for you as well I guess. And you don't need to explicitly have the subscription, as you already have created the quote through the API. So you can just immediately trigger the macro afterwards.

+1

Thanks Dennis!

What we do is create a dummy account called "Sales Department" and connect that to a general alias (sales@). Our Zaps and other API connected apps set the Sales Department as the sales person and account manager. We have a similar alias for general Project Management. I've then written a slack integration that pings our sales slack channel and it is determined there who takes it and that person is responsible for setting themselves as the sales manager when they take over the quote. Hokey, but works for now.


As our sales team grows, since we are using Wordpress, we can get the IP or other geolocation data from the form output and then do some logic around which sales person gets which regions and auto assign based on that, and default to the Sales Department XTRF account when it can't determine. Tested in Zapier and FlowXO and possible in both.


Just an update on the Zapier vs. FlowXO thing, Defintiely working to moving to FlowXO. Zapier is easier, drag and drop to build connections whereas FlowXO is more codey, but thing is Zapier charges you an action for each action in a Zap. So you run out of actions fast if you have complicated zaps (which we of course do because we are using Classic projects, so you have to go through multiple steps to create a quote).  FlowXO only charges you once per fired task, so much more economical.

So Cori, do you have a generic XTRF account for Sales in addition to individual sales people? I do wish xtrf licencing would allow us to create alias accounts without having to be charged a full licence.

I'm not sure about the different plans, but we don't get charged for creating an account: It is all about concurrent licences. Since the Sales Department account never actually logs in, it doesn't eat up any of our licences, so far as I understand. Are you guys on SaaS or on premise?

That would suggest Cori uses floating licenses and Mark - name licenses.

I've never heard of floating licenses. I want to learn more about that. Is that possible?

Thanks. That's helpful.

You are probably right that the sales person is the one for whom the API credentials are being used.