Managing vendor agreements across procurement and finance systems often requires manually downloading executed contracts and attaching them to vendor records. This can become time-consuming and difficult to manage when dealing with a large number of contracts.
In this post, we’ll share a simple automation built using Zoho Flow, Zoho Contracts APIs, and Zoho Books that connects procurement, legal, and finance workflows.
This integration automatically:
- Creates counterparties and contracts in Zoho Contracts when a vendor is added in Zoho Books
- Detects when a contract is executed in Zoho Contracts
- Downloads the executed contract
- Attaches the signed contract to the vendor record in Zoho Books
This enables a seamless Procure-to-Pay vendor contract workflow and demonstrates how Zoho Contracts can be integrated with finance systems to streamline vendor agreement management.
Business Use Case – Procure to Pay
A typical vendor agreement lifecycle involves:
- Vendor onboarding in Zoho Books
- Contract creation, negotiation, and execution in Zoho Contracts
- Executed agreement available for the finance team’s reference
Without automation, finance teams must manually download the executed agreement and attach it to the vendor record.
Prerequisites
Before implementing this automation, ensure the following setup is completed:
- Zoho Books and Zoho Contracts are configured in your organization
- Zoho Flow is enabled and connected to both Zoho Books and Zoho Contracts
- API connections are configured for Zoho Books and Zoho Contracts in Zoho Flow
- Appropriate permissions are available to create counterparties and contracts in Zoho Contracts
- Additionally, create a custom field in Zoho Books (Vendor module) to store the Zoho Contracts Counterparty API Name.
Example:
- Field Name: Contracts Counterparty ID
- Field Type: Text
- Module: Vendors
This field helps map vendors in Zoho Books with their corresponding counterparties in Zoho Contracts.
Solution Overview
Zoho applications involved:
- Zoho Contracts
- Zoho Books
- Zoho Flow
The automation is implemented using two flows.
Flow 1 – Vendor Creation → Contract Creation
Trigger: A new vendor is created in Zoho Books.
Actions:
- Zoho Flow detects the new vendor.
- A custom function checks whether a corresponding counterparty exists in Zoho Contracts
- If the counterparty does not exist, a new counterparty is created in Zoho Contracts
- The counterparty API name is stored in Zoho Books
- A contract is automatically created in Zoho Contracts for that vendor
Custom Function Snippet (Create Counterparty and Contract):
Note: The custom functions shared below are working reference implementations. However, depending on your environment, you may need to update certain values before using them in your setup.
Please review and update the following as applicable:
- Connection names used in the invokeurl statements
- Organization ID used for Zoho Books API calls
- Custom field API names used to store the Counterparty reference in Zoho Books
- Contract type API names configured in Zoho Contracts
Ensure these values are updated according to your configuration before deploying the automation
.
- map createContract1(string vendorName, string vendorID, string counterpartyID)
- {
- result = Map();
- createdCounterPartyAPIName = "";
- if(counterpartyID != null && counterpartyID != "")
- {
- existingCounterpartyResponse = invokeurl
- [
- url :"https://contracts.zoho.in/api/v1/counterparties/" + counterpartyID
- type :GET
- connection:"zcontractsconn"
- ];
- if(existingCounterpartyResponse.get("counterparty") != null)
- {
- createdCounterPartyAPIName = existingCounterpartyResponse.get("counterparty").get("apiName");
- }
- }
- if(createdCounterPartyAPIName == "")
- {
- counterpartyMap = Map();
- counterpartyMap.put("name",vendorName);
- counterpartyMap.put("counterPartyType","vendor");
- createResponse = invokeurl
- [
- url :"https://contracts.zoho.in/api/v1/counterparties"
- type :POST
- parameters:counterpartyMap.toString()
- connection:"zcontractsconn"
- ];
- counterpartyDetail = createResponse.getJSON("counterparties").get(0);
- createdCounterPartyAPIName = counterpartyDetail.get("organizationApiName");
- customFields = List();
- cf = Map();
- cf.put("api_name","cf_contracts_counterparty_id");
- cf.put("value",createdCounterPartyAPIName);
- customFields.add(cf);
- updateMap = Map();
- updateMap.put("custom_fields",customFields);
- updateVendor = invokeurl
- [
- url :"https://books.zoho.in/api/v3/vendors/" + vendorID + "?organization_id=60047651581"
- type :PUT
- parameters:updateMap
- connection:"zbooks"
- ];
- }
- info "STEP 4 STARTED - Preparing Contract Variables";
- newContractType = "master-subscription-agreement-pro-plus";
- newContractName = "Agreement with " + vendorName;
- isNewContractTermIsDefinite = false;
- isNewContractRenewable = false;
- contractEffectiveDate = 1;
- info "Contract Type: " + newContractType;
- info "Contract Name: " + newContractName;
- info "Counterparty API Name: " + createdCounterPartyAPIName;
- newContractDetail = {"externalSource":true,"inputfields":{{"metaApiName":"contract-type","inputs":{{"inputApiName":"contract-type","inputValue":newContractType}}},{"metaApiName":"contract-term","inputs":{{"inputApiName":"contract-term","inputValue":isNewContractTermIsDefinite}}},{"metaApiName":"is-renewable","inputs":{{"inputApiName":"is-renewable","inputValue":isNewContractRenewable}}},{"metaApiName":"title","inputs":{{"inputApiName":"title","inputValue":newContractName}}},{"metaApiName":"party-b-name","inputs":{{"inputApiName":"party-b-name","inputValue":createdCounterPartyAPIName}}},{"metaApiName":"contract-effective-date","inputs":{{"inputApiName":"contract-effective-date","inputValue":contractEffectiveDate}}}}};
- createContractResponse = invokeurl
- [
- url :"https://contracts.zoho.in/api/v1/createcontract"
- type :POST
- body:newContractDetail.toString()
- headers:{"Content-Type":"application/json"}
- connection:"zcontractsconn"
- ];
- info createContractResponse;
- result.put("counterpartyApiName",createdCounterPartyAPIName);
- result.put("contractResponse",createContractResponse);
- return result;
- }
Flow 2 – Contract Execution → Attach Signed Agreement
Trigger: Contract signing is completed in Zoho Contracts
Actions:
- Zoho Flow detects the contract execution event
- A custom function calls the Zoho Contracts API to download the executed contract document.
- The function identifies the corresponding vendor in Zoho Books.
- The executed agreement is automatically attached to the vendor record in Zoho Books.
Custom Function Snippet (Retrieve and Attach Signed Contract):
- map attachSignedContractToVendor(string contractApiName, string contractTitle)
- {
- result = Map();
- orgID = "60047651581";
- info "FLOW 2 STARTED";
- info contractApiName;
- info contractTitle;
- if(contractApiName.startsWith("contract/"))
- {
- contractApiName = contractApiName.replaceAll("contract/","");
- }
- info "Clean Contract API Name: " + contractApiName;
- if(contractTitle.startsWith("Agreement with "))
- {
- vendorName = contractTitle.subString(15);
- }
- else
- {
- vendorName = contractTitle;
- }
- info "Vendor Extracted: " + vendorName;
- vendorSearch = invokeurl
- [
- url :"https://books.zoho.in/api/v3/contacts?contact_name=" + vendorName + "&organization_id=" + orgID
- type :GET
- connection:"zbooks"
- ];
- info vendorSearch;
- contactsList = vendorSearch.get("contacts");
- if(contactsList == null || contactsList.size() == 0)
- {
- info "Vendor not found";
- result.put("status","vendor_not_found");
- return result;
- }
- vendorID = contactsList.get(0).get("contact_id");
- info "Vendor ID: " + vendorID;
- info "Downloading signed contract";
- signedFile = invokeurl
- [
- url :"https://contracts.zoho.in/api/v1/download/contracts/" + contractApiName + "/signed/document"
- type :GET
- connection:"zcontractsconn"
- ];
- info signedFile;
- fileMap = Map();
- fileMap.put("attachment",signedFile);
- fileMap.put("organization_id",orgID);
- info "Uploading attachment to Zoho Books";
- uploadResponse = invokeurl
- [
- url :"https://books.zoho.in/api/v3/contacts/" + vendorID + "/attachment?organization_id=" + orgID
- type :POST
- parameters:fileMap
- connection:"zbooks"
- content-type:"multipart/form-data"
- ];
- info uploadResponse;
- result.put("uploadResponse",uploadResponse);
- info "FLOW 2 COMPLETED";
- return result;
- }
Benefits
- This automation provides several advantages:
- Eliminates manual document handling
- Ensures finance teams always have access to executed agreements
- Connects legal and finance workflows
- Improves compliance and audit readiness
- Reduces operational friction
Closing
If you're implementing Procure-to-Pay contract workflows, this approach can help streamline the connection between Zoho Contracts and finance systems like Zoho Books.
We’d be happy to discuss variations of this implementation or answer any questions.
If you're planning to implement a similar workflow and need guidance, feel free to reach out to the Zoho Contracts support team at
support@zohocontracts.com.
.
Stay tuned for more tips, tricks, and automation ideas around Zoho Contracts.
Cheers,
Sathyakeerthi
Zoho Contracts Team
Recent Topics
FSM integration with Books
Hi, I have spent a few months working with FSM and have come across a critical gap in the functionality, which I find almost shocking....either that, or I am an idiot. The lack of bi-directional sync between Books and FSM on Sales Orders/ Work Orders
How to close an estimate ?
Hello, I have created estimates, and converted them to invoices to get 50% payment. Now I have 2 cases where the estimate stills shows status partially invoiced, however: 1. for one of them, project stopped half way, so the remaining part will never be
Power up your Kiosk Studio with Real-Time Data Capture, Client Scripts & More!
Hello Everyone, We’re thrilled to announce a powerful set of enhancements to Kiosk Studio in Zoho CRM. These new updates give you more flexibility, faster record handling, and real-time data capture, making your Kiosk flows smarter and more efficient
How do you print out the invoices comments
I have some invoices where i need to print out the comments that show when reminders and etc were sent how do we print those out in Zoho Books.
Unable to load a specific image
Hi I am trying to upload an svg file, which reports that there is "a problem with the file", but does not say what sort of problem. I can't find anything which says which files are supported, so it may be it does not support svg. (which would be a real shame) The file itself will open in either Firefox or Chrome without problem. For the moment I am using a png file, which does not zoom well of course. David
Why does the Address field show the wrong map location even with a correct Pincode?
I am noticing an issue with the Address field map in Zoho Creator. When I enter a city name that exists in multiple locations within the same state, the map sometimes points to the wrong area even if I have entered the correct Pincode. Currently, it seems
Books <-> CRM synchronisation with custom Fields
Hello, We are synchronising Books Customers with CRM Accounts. In CRM Accounts I set up last year a "segments" multiselect field shown below In Books, I set up a custom multi-select field with the same value as in the CRM And set up the synchronisation inside Books. Want to synchronise the Books Segments with the CRM Segments, but the later doesn't exist, and another non-existing is there ?! First, I don't understand where the field Segmentation is coming from. Second, I set CRM Segmentation to sync
CRM x WorkDrive: We're rolling out the WorkDrive-powered file storage experience for existing users
Release plan: Gradual rollout to customers without file storage add-ons, in this order: 1. Standalone CRM 2. CRM Plus and Zoho One DCs: All | Editions: All Available now for: - Standalone CRM accounts in Free and Standard editions without file storage
Archive Option in Conversation View
Hello, I have a suggestion\request to add an "Archive Thread" button in conversation view of Zoho Mail. The best suggestion I have is to put an "Archive Thread" button next to the "Label Entire Thread" button in conversation view. Most users don't just
Outlook/Hotmail Blocking Zoho SMTP IPs (S3150)
We are currently facing a serious deliverability issue with Zoho SMTP while sending transactional OTP emails for our production application. Emails sent to Outlook / Hotmail addresses are being rejected with the following error: 550 - 5.7.1 Unfortunately,
Outlook is blocking incoming mail
Outlook is blocking all emails sent from the Zoho server. ERROR CODE :550 - 5.7.1 Unfortunately, messages from [136.143.169.51] weren't sent. Please contact your Internet service provider since part of their network is on our block list (S3150). It looks
Track Marketing Automation Campaigns in Zoho CRM
Hello, I've been searching but haven't found the exact answer to this question. I am looking to track Marketing Automation email campaigns and activities inside of Zoho CRM. Use Case: Action: Prospect Submits A Lead Form Outcomes: Prospect created in
Zoho Social API for generating draft posts from a third-party app ?
Hello everyone, I hope you are all well. I have a question regarding Zoho Social. I am developing an application that generates social media posts, and I would like to be able to incorporate a feature that allows saving these posts as drafts in Zoho Social.
Temporarily rate limited due to IP reputation.
We have suddenly started receiving the following Mail Delivery Status Notification: Diagnostic-Code: 4.7.650 The mail server [136.143.184.12] has been temporarily rate limited due to IP reputation. For e-mail delivery information, see https://aka.ms/postmaster
Incorrect Functioning of Time Logs API (Version 3)
We need to fetch the list of time logs for each task for our company internal usage. We are trying to achieve it by using the next endpoint: https://projects.zoho.com/api-docs#bulk-time-logs#get-all-project-time-logs Firstly, in the documentation the
IMPORTANT: It doesn´t search for letters with portuguese characters.
Some of my articles have for example the word "vídeo". But if I search for "vídeo" it doesn´t find them. If I search for "video" it does find them. Idealy, it should find the articles either way. But if I have to choose, it would be better to find the
IMPORTANT: It doens´t show full article name on search - Should add line break
When we search for articles, it doesn´t show the full name. There should be a line break so the user can see the full article name, otherwise the user can´t know if that´s the article he/she is looking for. This is very important, otherwise the user has
Zoho Books - Payment Gateway - Revolut
Hi Books Team, My feature request if to include the popular platform Revolut as a payment collection option on invoices in Zoho Books. Please upvote if you are also looking for this option.
Zoho Books | Product updates | January 2026
Hello users, We’ve rolled out new features and enhancements in Zoho Books. From e-filing Form 1099 directly with the IRS to corporation tax support, explore the updates designed to enhance your bookkeeping experience. E-File Form 1099 Directly With the
Kaizen #233 - Generating AI-powered Follow-up Emails Using CRM Functions and Widgets
Hey everyone! Welcome back to another interesting post in the Kaizen series! Sales teams regularly capture interaction notes in CRM after speaking with prospects. However, drafting a follow-up email that reflects the conversation context can be repetitive
Connect Bank in Zoho Books
Can I connect UOB or Ariwallex in Zoho Books?
Using MPN across multiple SKUs and inventory tracking
I have several different SKU's that share a common MPN and would like to track inventory by MPN. SKU1 has MPN1 assigned SKU2 has MPN1 assigned Here is an example If I start with 5 of MPN 1 in stock I want each SKU1 and SKU2 to show as 5 in stock, If I
Extend Zoho Canvas Customization to Zoho Creator Forms and Reports
Currently, Zoho Canvas allows users to design and customize the UI of Zoho CRM modules with a much better visual experience. This helps organizations create cleaner layouts, improve usability, and design interfaces that match their workflows. However,
Marketing Tip #1: Optimize item titles for SEO
Your item title is the first thing both Google and shoppers notice. Instead of a generic “Leather Bag,” go for something detailed like “Handcrafted Leather Laptop Bag – Durable & Stylish.” This helps your items rank better in search results and instantly
Feature Enhancement Request – Text Formatting Options in Item Description (Zoho Books/Quotes Module)
Dear Zoho Development Team, Greetings from Radiant360 Integrated Technical Services LLC. We would like to bring to your attention a functional limitation we've encountered within the Item Table / Quote Description section of Zoho Books (and Zoho CRM Quotes).
ZOHO Books Query
Good day, Can someone please advise. I recently migrated from ZOHO Invoice to ZOHO Books. No that I want to use the inventory on Books I cant as all my items have transaction history. The person I spoke to at ZOHO said I need to create a new Company profile
Best way to schedule bill payments to vendors
I've integrated Forte so that I can convert POs to bills and make payments to my vendors all through Books. Is there a way to schedule the bill payments as some of my vendors are net 30, net 60 and even net 90 days. If I can't get this to work, I'll have
ZOHO.CRM.UI.Record.open not working properly
I have a Zoho CRM Widget and in it I have a block where it will open the blocks Meeting like below block.addEventListener("click", () => { ZOHO.CRM.UI.Record.open({ Entity: "Events", RecordID: meeting.id }).catch(err => { console.error("Open record failed:",
inventory removal at packing list or shipment.
currently our system is set to remove inventory at invoice. This is creating an inventory nightmare? Is it possible to change the settings to remove the item from inventory at either the packing slip stage or shipping the item.
How to add employee and not invite them to log in?
I want to add 50 employees, but invite them only when everything will be configured and ready. Is it possible? Should we create employee profiles and then convert them later? Thank you,
How is Your eCommerce Experience w/Zoho Inventory?
First off, I'm SUPER grateful for the advent of Zoho Inventory and now the Zoho Commerce Suite. Overall, Inventory is a great product, especially for customers without an eCommerce presence. For eCommerce companies (especially those shipping more than ~10 packages/day), however, there are certain drawbacks that keep my clients from moving over to Zoho Inventory: Cons: 1. Invoice + Package Creation from Shopify/Other eCommerce Integrations: Zoho Inventory makes the somewhat perplexing decision to
Ability to Use Both AND and OR When Creating Rules (Advanced Conditions)
I'd like to be able to use more complicated logic when setting up rules. E.g. in Zoho Mail, I can choose "Advanced conditions (AND/OR) to create a rule that can be applied to multiple subject lines from the same sender. But in Zoho TeamInbox, I will have
Zoho Desktop App- Unable to Minimize/Freezes
I'm having issues with my Zoho Mail desktop app (PC). When go on my desktop and open the app this is what happens: - Unable to minimize and close app (in the screenshot attached you can see at the top right there is no option to minimize/close) - Unable
Zoho Invoice Zapier Integration
Is there still a way to use Zapier with Zoho Invoice? I've read online that that migrated to Zoho Books or Billing but since I am just using Invoice I can not find a Zapier Connection anymore.
Conect chat of salesiq with zoho cliq
Is there any way to answer from zoho cliq the chat of salesiq initiated by customers?
Bug: OAuth 2.0 State Parameter fails with Pipe Delimiters (RFC 6749 Non-Compliance)
I've discovered a bug in how Zoho's API Console handles the OAuth 2.0 authorization flow when the state parameter contains pipe characters (|), and I'm hoping the Zoho team can address this in a future update. The Issue Zoho's OAuth 2.0 implementation
Zobot with Plugs
Hello, I am having a problem with Zobot using Plugs. Here is my current flow: When I run the flow, I should immediately see the messages from the initial cards (Send Message cards), then after running the plug, and finally, see the messages after the
Print a document from Zoho Writer via Zoho Creator
If i use the code below i can get writer to create a new document or email it to me but i want to be able to print it directly from the browser and not have to send it via email and then print. Below is the code im using. Attached options form zoho writer
Training for How can i Operate the Software Features
need to Help for Training of the ZOHO Billing Software
Automating Vendor Contract Management between Zoho Contracts and Zoho Books using Zoho Flow
Managing vendor agreements across procurement and finance systems often requires manually downloading executed contracts and attaching them to vendor records. This can become time-consuming and difficult to manage when dealing with a large number of contracts.
Next Page