Sample Codes
All of Zoho CRM's APIs can be used through the C# SDK, to enable your custom application to perform data sync to the best degree. Here are the sample codes for all the API methods available in our SDK.
Assignment Rules Operations
Method | Description |
---|---|
Get Assignment Rules | To fetch the assignment rules of a record. |
Get Assignment Rule | To fetch the assignment rule of a record. |
Attachment Operations
Constructor | Description |
---|---|
AttachmentsOperations(string moduleAPIName, string recordId) | Creates an AttachmentsOperations class instance with the moduleAPIName and recordId. |
Method | Description |
---|---|
GetAttachments | To fetch the list of attachments of a record. |
UploadAttachments | To upload attachments to a record. |
DeleteAttachments | To delete the attachments that were added to a record. |
DeleteAttachment | To delete an attachment that was added to a record. |
DownloadAttachment | To download an attachment that was uploaded to a record. |
UploadLinkAttachments | To upload a link as an attachment to a record. |
Blueprint Operations
Constructor | Description |
---|---|
BluePrintOperations(string recordId, string moduleAPIName) | Creates a BluePrintOperations class instance with the recordId and moduleAPIName. |
Method | Description |
---|---|
GetBlueprint | To get the next available transitions for that record, fields available for each transition, current value of each field, and validation(if any). |
UpdateBlueprint | To update a single transition at a time. |
Bulk Read Operations
Method | Description |
---|---|
CreateBulkReadJob | To schedule a bulk read job to export records that match the criteria. |
GetBulkReadJobDetails | To know the status of the bulk read job scheduled previously. |
DownloadResult | To download the result of the bulk read job. The response contains a zip file. Extract it to get the CSV or ICS file depending on the "file_type" you specified while creating the bulk read job |
Bulk Write Operations
Method | Description |
---|---|
UploadFile | To upload a CSV file in ZIP format. The response contains the "file_id". Use this ID while making the bulk write request. |
CreateBulkWriteJob | To create a bulk write job to insert, update, or upsert records. The response contains the "job_id". Use this ID while getting the status of the scheduled bulk write job. |
GetBulkWriteJobDetails | To know the status of the bulk write job scheduled previously. |
DownloadResult | To download the result of the bulk write job. The response contains a zip file. Extract it to get the CSV or ICS file depending on the "file_type" you specified while creating the write job |
Contact Roles Operations
Method | Description |
---|---|
GetContactRoles | To get the list of all contact roles. |
CreateContactRoles | To create contact roles. |
UpdateContactRoles | To update contact roles. |
DeleteContactRoles | To delete contact roles. |
GetContactRole | To get specific contact role. |
UpdateContactRole | To update specific contact role. |
DeleteContactRole | To delete specific contact role. |
GetAllContactRolesOfDeal | To get all contact roles of deal. |
GetContactRoleOfDeal | To get contact role of deal. |
AddContactRoleToDeal | To add contact role to deal. |
RemoveContactRoleFromDeal | To remove specific contact role from deal. |
Currencies Operations
Method | Description |
---|---|
GetCurrencies | To get the list of all currencies available for your org. |
AddCurrencies | To add new currencies to your org. |
UpdateCurrencies | To update the currencies' details of your org. |
EnableMultipleCurrencies | To enable multiple currencies for your org. |
UpdateBaseCurrency | To update the base currency details of your org. |
GetCurrency | To get the details of specific currency. |
UpdateCurrency | To update the details of specific currency. |
Custom View Operations
Constructor | Description |
---|---|
CustomViewsOperations(string module) | Creates a CustomViewsOperations class instance with the moduleAPIName. |
Method | Description |
---|---|
GetCustomViews | To get the list of all custom views in a module. |
GetCustomView | To get the details of specific custom view in a module. |
Email Templates Operations
Method | Description |
---|---|
Get Email Templates | To fetch all the email templates. |
Get Email Template | To fetch a particular email template. |
Fields Metadata Operations
Constructor | Description |
---|---|
FieldsOperations(string module) | Creates a FieldsOperations class instance with the module. |
Files Operations
Method | Description |
---|---|
UploadFiles | To upload files and get their encrypted IDs. |
GetFile | To get the uploaded file through its encrypted ID. |
Inventory Templates Operations
Method | Description |
---|---|
Get Inventory Templates | To fetch all the inventory templates. |
Get Inventory Template | To fetch a particular inventory template. |
Layouts Operations
Constructor | Description |
---|---|
LayoutsOperations(string module) | Creates a LayoutsOperations class instance with the moduleAPIName. |
Method | Description |
---|---|
GetLayouts | To get the details of all the layouts in a module. |
GetLayout | To get the details (metadata) of a specific layout in a module. |
Modules Operations
Method | Description |
---|---|
GetModules | To get the details of all the modules. |
GetModule | To get the details (metadata) of a specific module. |
UpdateModuleByAPIName | To update the details of a module by its module API name. |
UpdateModuleById | To update the details of a module by its ID. |
Notes Operations
Method | Description |
---|---|
GetNotes | To get the list of notes of a record. |
CreateNotes | To add new notes to a record. |
UpdateNotes | To update the details of the notes of a record. |
DeleteNotes | To delete the notes of a record. |
GetNote | To get the details of a specific note. |
UpdateNote | To update the details of an existing note. |
DeleteNote | To delete a specific note. |
Notification Operations
Method | Description |
---|---|
EnableNotifications | To enable instant notifications of actions performed on a module. |
GetNotificationDetails | To get the details of the notifications enabled by the user. |
UpdateNotifications | To update the details of the notifications enabled by a user. All the provided details would be persisted and rest of the details would be removed. |
UpdateNotification | To update only specific details of a specific notification enabled by the user. All the provided details would be persisted and rest of the details will not be removed. |
DisableNotifications | To stop all the instant notifications enabled by the user for a channel. |
DisableNotification | To disable notifications for the specified events in a channel. |
Organization Operations
Method | Description |
---|---|
GetOrganization | To get the details of your organization. |
UploadOrganizationPhoto | To upload a photo of your organization. |
Pipeline Operations
Method | Description |
---|---|
Transfer Delete | To transfer and delete. |
Get Pipelines | To get all the pipelines. |
Create Pipelines | To create pipelines. |
Update Pipelines | To update pipelines. |
Get Pipeline | To get a particular pipeline. |
Update Pipeline | To update pipeline. |
Profile Operations
Constructor | Description |
---|---|
ProfilesOperations(OffsetDateTime ifModifiedSince) | Creates a ProfilesOperations class instance with the value of the If-Modified-Since header. |
Method | Description |
---|---|
GetProfiles | To get the list of profiles available for your organization. |
GetProfile | To get the details of a specific profile. |
Query (COQL) Operation
Method | Description |
---|---|
getRecords | To get the records from a module through a COQL query. |
Records Operations
Method | Description |
---|---|
GetRecord | To get a specific record from a module. |
UpdateRecord | To update a specific record in a module. |
DeleteRecord | To delete a specific record from a module. |
GetRecordsUsingExternalID | To get records using external ID. |
UpdateRecordsUsingExternalID | To update records using external ID. |
DeleteRecordsUsingExternalID | To delete records using external ID. |
GetRecords | To get all records from a module. |
CreateRecords | To insert records in a module. |
UpdateRecords | To update records in a module. |
DeleteRecords | To delete records from a module. |
UpsertRecords | To insert/update records in a module. |
GetDeletedRecords | To get the deleted records from a module. |
SearchRecords | To search for records in a module that match certain criteria, email, phone number, or a word. |
ConvertLead | To convert records(Leads to Contacts/Deals). |
GetPhoto | To get the photo of a record. |
UploadPhoto | To upload a photo to a record. |
DeletePhoto | To delete the photo of a record. |
MassUpdateRecords | To update the same field for multiple records in a module. |
GetMassUpdateStatus | To get the status of the mass update job scheduled previously. |
AssignTerritoriesToMultipleRecords | To assign territories to multiple territories to multiple records. |
AssignTerritoryToRecord | To assign territory to a single record. |
RemoveTerritoriesFromMultipleRecords | To remove territories from multiple records. |
RemoveTerritoryFromRecord | To remove territories from a single record. |
Related List Operations
Constructor | Description |
---|---|
RelatedListsOperations(string module) | Creates a RelatedListsOperations class instance with the moduleAPIName. |
Method | Description |
---|---|
GetRelatedLists | To get the details of all the related lists of a module. |
GetRelatedList | To get the details of a specific related list of a module. |
Related Records Operations
Constructor | Description |
---|---|
RelatedRecordsOperations(string relatedListAPIName, long recordId, string moduleAPIName) | Creates a RelatedRecordsOperations class instance with the relatedListAPIName, recordId, and moduleAPIName. |
Method | Description |
---|---|
GetRelatedRecords | To get list of records from the related list of a module. |
UpdateRelatedRecords | To update the association/relation between the records. |
DelinkRecords | To delete the association between the records. |
GetRelatedRecordsUsingExternalId | To get the records using External ID. |
UpdateRelatedRecordsUsingExternalId | To update the association/relation between the records using External ID. |
DeletedRelatedRecordsUsingExternalId | To delete the association between the records using External ID. |
GetRelatedRecord | To get the records from a specific related list of a module. |
UpdateRelatedRecord | To update the details of a specific record of a related list in a module. |
Delink Record | To delete a specific record from the related list of a module. |
GetRelatedRecordUsingExternalId | To get the record using External ID. |
UpdateRelatedRecordUsingExternalId | To update the association/relation between the record using External ID. |
DeleteRelatedRecordsUsingExternalId | To delete the association between the record using External ID. |
Role Operations
Send Mail Operations
Method | Description |
---|---|
GetEmailAddresses | To get the list of all email addresses. |
SendMail | To send an email. |
Shared Records Operations
Constructor | Description |
---|---|
ShareRecordsOperations(long recordId, string moduleAPIName) | Creates a ShareRecordsOperations class instance with the recordId and moduleAPIName. |
Method | Description |
---|---|
GetSharedRecordDetails | To get the details of a record shared with other users. |
ShareRecord | To share a record with other users in the organization. |
UpdateSharePermissions | To
|
RevokeSharedRecord | To revoke access to a shared record. |
Tags Operations
Method | Description |
---|---|
GetTags | To get the list of all tags in your organization. |
CreateTags | To create tags. |
UpdateTags | To update multiple tags. |
UpdateTag | To update a specific tag. |
DeleteTag | To delete a specific tag from the module. |
MergeTags | To merge two tags. |
AddTagsToRecord | To add tags to a specific record. |
RemoveTagsFromRecord | To remove tags from a record. |
AddTagsToMultipleRecords | To add tags to multiple records. |
RemoveTagsFromMultipleRecords | To remove tags from multiple records. |
GetRecordCountForTag | To get the record count for a tag. |
Taxes Operations
Method | Description |
---|---|
GetTaxes | To get the taxes of your organization. |
CreateTaxes | To add taxes to your organization. |
UpdateTaxes | To update the existing taxes of your organization. |
DeleteTaxes | To delete multiple taxes from your organization. |
GetTax | To get the details of a specific tax. |
DeleteTax | To delete a specific tax from your organization. |
Territory Operations
Method | Return Type | Description |
---|---|---|
GetTerritories | APIResponse<ResponseHandler> | To get the list of all territories. |
GetTerritory | APIResponse<ResponseHandler> | To get the details of a specific territory. |
Users Operations
Method | Description |
---|---|
GetUsers | To get the list of users in your organization. |
CreateUser | To add a user to your organization. |
UpdateUsers | To update the existing users of your organization. |
GetUser | To get the details of a specific user. |
UpdateUser | To update the details of a specific user. |
DeleteUser | To delete a specific user from your organization. |
Variable Groups Operations
Method | Description |
---|---|
GetVariableGroups | To get the list of all variable groups available for your organization. |
GetVariableGroupById | To get the details of a variable group by its group ID. |
GetVariableGroupByAPIName | To get the details of a specific variable group by its API name. |
Variables Operations
Method | Description |
---|---|
GetVariables | To get the list of variables available for your organization. |
CreateVariables | To add new variables to your organization. |
UpdateVariables | To update the details of variables. |
DeleteVariables | To delete multiple variables. |
GetVariableById | To get the details of a specific variable by its unique ID. |
UpdateVariableById | To update the details of a specific variable by its unique ID. |
DeleteVariable | To delete a specific variable. |
GetVariableForAPIName | To get the details of a variable by its API name. |
UpdateVariableByAPIName | To update the details of a variable by its API name. |
Wizards Operations
Method | Description |
---|---|
Get Wizards | To get the list of wizards available. |
Get Wizard | To get a particular wizard. |