This site contains the documentation that is relevant to older WSO2 product versions and offerings.
For the latest WSO2 documentation, visit https://wso2.com/documentation/.
Working with Organizations in Pipedrive
Overview
The following operations allow you to work with organizations . Click an operation name to see details on how to use it.
For a sample proxy service that illustrates how to work with organizations , see Sample configuration.
Operation | Description |
---|---|
Adds a new organization. | |
listOrganizations | Retrieves all organizations. |
searchOrganizations | Searches all organizations by their name. |
Operation details
This section provides further details on the operations related to organizations .
Adding a new organization
The createOrganization operation adds a new organization.
<pipedrive.createOrganization> <addedTime>{$ctx:addedTime}</addedTime> <visibility>{$ctx:visibility}</visibility> <customFields>{$ctx:customFields}</customFields> <prettyOutput>{$ctx:prettyOutput}</prettyOutput> <ownerId>{$ctx:ownerId}</ownerId> <name>{$ctx:name}</name> <fields>{$ctx:fields}</fields> </pipedrive.createOrganization>
Properties
Optional creation date and time of the organization in UTC. Requires admin user API token. Format: YYYY-MM-DD HH:MM:SS.addedTime:
Visibility of the organization. If omitted, visibility will be set to the default visibility, possible values are 0,1,2.visibility:
JSON object specifying the values for the organization's custom fields created in the account, keys for the object are the 40-character hashes assigned for the respective custom fields.customFields:
If the prettyOutput is specified as 1, will return an indented response of the output.prettyOutput:
The ID of the user who will be marked as the owner of this organization.ownerId:
The name of the organization.name:
The array of fields to be returned in the output.fields:
Sample request
Following is a sample REST/JSON request that can be handled by the createOrganization operation.
{ "apiToken":"7ccee3fe30e479ae845169ec8601ba8b4ab2be0d", "apiUrl":"https://api.pipedrive.com", "addedTime":"2015-01-01 10:30:22", "visibility":0, "customFields":{"2a647187c61990632d8cd86c3037bd8fc076b595":"testValue1", "29443e8cba4d62d2b080098ff7d072dd0ffa054f":"testValue2"}, "prettyOutput":1, "ownerId":589352, "name":"Org1", "fields":["id", "name"] }
Related Pipedrive documentation
https://developers.pipedrive.com/v1#methods-Organizations
Retrieving all organizations
The listOrganizations operation retrieves all organizations.
<pipedrive.listOrganizations> <limit>{$ctx:limit}</limit> <sort>{$ctx:sort}</sort> <filterId>{$ctx:filterId}</filterId> <start>{$ctx:start}</start> <prettyOutput>{$ctx:prettyOutput}</prettyOutput> <fields>{$ctx:fields}</fields> </pipedrive.listOrganizations>
Properties
The number of items shown per page.limit:
The field names and sorting mode separated by comma(i.e.,field_name_1 ASC, field_name_2 DESC).sort:
The unique identifier of the filter to be used.filterId:
The start of the pagination.start:
If the prettyOutput is specified as 1, will return an indented response of the output.prettyOutput:
The array of fields to be returned in the output.fields:
Sample request
Following is a sample REST/JSON request that can be handled by the listOrganizations operation.
{ "apiToken":"7ccee3fe30e479ae845169ec8601ba8b4ab2be0d", "apiUrl":"https://api.pipedrive.com", "limit":10, "sort":["id DESC"], "filterId":12, "start":0, "prettyOutput":1, "fields":["id","name","open_deals_count"] }
Related Pipedrive documentation
https://developers.pipedrive.com/v1#methods-Organizations
Searching all organizations by their name
The
operation searches for all organizations by their name.searchOrganizations
<pipedrive.searchOrganizations> <term>{$ctx:term}</term> <prettyOutput>{$ctx:prettyOutput}</prettyOutput> <fields>{$ctx:fields}</fields> <start>{$ctx:start}</start> <limit>{$ctx:limit}</limit> </pipedrive.searchOrganizations>
Properties
The search term to look for organizations.term:
If the prettyOutput is specified as 1, will return an indented response of the output.prettyOutput:
The array of fields to be returned in the output.fields:
Specifies the pagination start index.start:
Specifies the number of items returned per page.limit:
Sample request
Following is a sample REST/JSON request that can be handled by the
operation.searchOrganizations
{ "apiToken":"39126d07e28ce7e3a62bc49b50ad51adc82b5f91", "apiUrl":"https://api.pipedrive.com", "term":"test", "prettyOutput" : 1, "fields" : ["id", "name"], "start" : 0, "limit" : 10 }
Related Pipedrive documentation
https://developers.pipedrive.com/v1#methods-Organizations
Sample configuration
Following is a sample proxy service that illustrates how to connect to Pipedrive with the init
operation and use the createOrganization operation. The sample request for this proxy can be found in the createOrganization sample request. You can use this sample as a template for using other operations in this category.
<?xml version="1.0" encoding="UTF-8"?> <proxy xmlns="http://ws.apache.org/ns/synapse" name="pipedrive_createOrganization" transports="https,http" statistics="disable" trace="disable" startOnLoad="true"> <target> <inSequence> <property name="apiToken" expression="json-eval($.apiToken)"/> <property name="apiUrl" expression="json-eval($.apiUrl)"/> <property name="addedTime" expression="json-eval($.addedTime)"/> <property name="visibility" expression="json-eval($.visibility)"/> <property name="customFields" expression="json-eval($.customFields)"/> <property name="prettyOutput" expression="json-eval($.prettyOutput)"/> <property name="ownerId" expression="json-eval($.ownerId)"/> <property name="name" expression="json-eval($.name)"/> <property name="fields" expression="json-eval($.fields)"/> <pipedrive.init> <apiToken>{$ctx:apiToken}</apiToken> <apiUrl>{$ctx:apiUrl}</apiUrl> </pipedrive.init> <pipedrive.createOrganization> <addedTime>{$ctx:addedTime}</addedTime> <visibility>{$ctx:visibility}</visibility> <customFields>{$ctx:customFields}</customFields> <prettyOutput>{$ctx:prettyOutput}</prettyOutput> <ownerId>{$ctx:ownerId}</ownerId> <name>{$ctx:name}</name> <fields>{$ctx:fields}</fields> </pipedrive.createOrganization> <respond/> </inSequence> <outSequence> <send/> </outSequence> </target> <description/> </proxy>