Bulk associations: POST /external/api/associations
Before you start
Before you start working with REST APIs, make sure you have:
Checked the Authenticate API instructions.
Use the Connector for Salesforce and Jira Cloud instance URL: https://sfjc.integration.appfire.app or https://eu-sfjc.integration.appfire.app, depending on your data residency location.
Endpoint: POST/external/api/associations?jiraIssueId{a Jira issue Id}&replace={true/false}
Description
Allows adding multiple associations for a single Jira issue. The replace parameter determines whether existing associations are overwritten.
Query parameters
jiraIssueId(string, required): The Jira issue IDreplace(boolean, optional): Whether to replace existing associations. The default value is set to false.
Example
POST /external/api/associations?jiraIssueId=11816&replace=trueRequest body
son(string, required): Salesforce object name, for example,Case,Account,Contact.soid(string, required): Salesforce object ID for the specific record associated with the Jira issue.viewOnly(boolean, optional):truefor a view-only association.autoPush(boolean, optional):truefor automatic data push from Jira to Salesforce.autoPull(boolean, optional):truefor automatic data pull from Jira to Salesforce.
Example request body
{
"associations": [
{
"son": "Case",
"soid": "500J80000019IF9IAM",
"viewOnly": false,
"autoPush": false,
"autoPull": false
}
]
}Example response body
totalAssociations is the total association count on the Jira issue
{
"data": {
"totalAssociations": 2
},
"message": "Associations created successfully",
"success": true
}Constraints
Maximum 1000 associations per Jira issue.
When
replace=true, all previous associations are removed before adding the new ones.Existing associations are not duplicated when
replace=false.
Related pages
Need support? Create a request with our support team.
