How can I get attachment from Jira Issue and add it to the Salesforce Files object using Rest API?

Feroz Basha S October 30, 2021

I am working on Salesforce Jira integration. I am able to create issues from jira. If I attach any document to the Jira issues, I would like to save it in the salesforce attachments as well. I am not able to get a proper solution.

3 answers

1 accepted

1 vote
Answer accepted
Ravi Sagar _Sparxsys_
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 31, 2021

Hi @Feroz Basha S 

Yes you can do that using REST API using the following end point.

Endpoint: GET /rest/api/3/issue/KEY-123

In the JSON you will find an attachment section. How are you doing the integration to salesforce? using your own code or interface? If yes then yes you can access the attachments using the end point above and move the files to another system. I also covered this example here in case you want to see it in action.

I hope it helps.

Ravi

Feroz Basha S October 31, 2021

@Ravi Sagar _Sparxsys_ Thanks for the post. I am integrating with my own code. I tried to access the content URL but the response returns only this [Status=Found, StatusCode=302]. Response body returns nothing I would like to know if I am missing anything.

0 votes
Diana_Architect_ZigiWave
Marketplace Partner
Marketplace Partners provide apps and integrations available on the Atlassian Marketplace that extend the power of Atlassian products.
March 28, 2022

Hi @Feroz Basha S 

A bit late here but have you considered using an external solution to help you make the integration? If so, may I make a proposition? I'm Diana - a solutions architect at ZigiWave.  Our no-code integration platform ZigOps will help you connect Jira & Salesforce in a matter of minutes. It allows the transfer of default and custom fields between the systems and syncs them in real-time. Our tool reads the schema dynamically and can transfer any field. If you want to see how it works in action: book a technical demo.

0 votes
Shubham Gupta November 1, 2021

Hi @Feroz Basha S 

If you are looking for the solution as well, with benefits like:

Map any project, Map Jira fields, Link Multi Jira's with salesforce record,  Push comments, attachment bidirectional, Bi-directional updates , Reporting try the third party integration tool.

I hope it helps!

Thanks

Suggest an answer

Log in or Sign up to answer