AuthenticationSupport only Basic auth but any authentication that will works against JIRA will work against the REST API. Content TypeUse "Content-Type: application/json" in http header when sending data to the REST-API's. |
Get Alfresco document Id linked to a Jira issueURLGET /rest/alfresco/latest/link/issue/{issueKey}/object RequestPATH PARAMETERS
QUERY PARAMETERS
BODY PARAMETERS
ResponseSTATUS 200 { "start": 0, "limit": 10, "size": 3, "results": [ "72948f84-4bf1-4ec5-8378-1bed0951600a", "1a0b110f-1e09-4ca2-b367-fe25e4964a4e", "05dedd34-9d9d-48d9-9af6-c81b555541c9" ] }
Examplecurl --request GET \ --url 'http://localhost:2990/jira/rest/alfresco/latest/link/issue/AAA-1/object?start=0&limit=10' \ --user admin:admin \ --header 'Accept: application/json' |
Get Alfresco document Id linked to a Jira projectURLGET /rest/alfresco/latest/link/project/{projectKey}/object RequestPATH PARAMETERS
QUERY PARAMETERS
BODY PARAMETERS
ResponseSTATUS 200 { "start": 0, "limit": 10, "size": 3, "results": [ "72948f84-4bf1-4ec5-8378-1bed0951600a", "1a0b110f-1e09-4ca2-b367-fe25e4964a4e", "05dedd34-9d9d-48d9-9af6-c81b555541c9" ] }
Examplecurl --request GET \ --url 'http://localhost:2990/jira/rest/alfresco/latest/link/project/AAA/object?start=0&limit=10' \ --user admin:admin \ --header 'Accept: application/json' |
Link Alfresco document to Jira IssuesURLPOST /rest/alfresco/latest/link/object/{objectId} RequestPATH PARAMETERS
QUERY PARAMETERS
BODY PARAMETERS{ "issueKeys": [ "AAA-1" ], "objects": [ { "objectId": "7bb7bfa8-997e-4c55-8bd9-2e5029653bc8" } ] } ResponseSTATUS 200 { "links": { "7bb7bfa8-997e-4c55-8bd9-2e5029653bc8": [ { "projectId": 10000, "issueId": 10000, "objectId": "7bb7bfa8-997e-4c55-8bd9-2e5029653bc8", "authorKey": "JIRAUSER10000", "username": "admin", "created": 1597597897073, "enableUnlink": true } ] } }
Example curl --request POST \ --url 'http://localhost:2990/jira/rest/alfresco/latest/link/object/7bb7bfa8-997e-4c55-8bd9-2e5029653bc8' \ --user admin:admin \ --header 'Accept: application/json' \ --header 'Content-Type: application/json' \ --data '{"issueKeys":["AAA-1"],"objects":[{"objectId":"7bb7bfa8-997e-4c55-8bd9-2e5029653bc8"}]}' NoteRequest parameter of "objectId" is Document Id of Alfresco. |
Unlink Alfresco document to Jira IssuesURLDELETE /rest/alfresco/latest/link/object/{objectId} RequestPATH PARAMETERS
QUERY PARAMETERS
BODY PARAMETERS{ "issueKeys": [ "AAA-1" ], "objects": [ { "objectId": "7bb7bfa8-997e-4c55-8bd9-2e5029653bc8" } ] } ResponseSTATUS 200 { "links": {} }
Example curl --request DELETE \ --url 'http://localhost:2990/jira/rest/alfresco/latest/link/object/7bb7bfa8-997e-4c55-8bd9-2e5029653bc8' \ --user admin:admin \ --header 'Accept: application/json' \ --header 'Content-Type: application/json' \ --data '{"issueKeys":["AAA-1"],"objects":[{"objectId":"7bb7bfa8-997e-4c55-8bd9-2e5029653bc8"}]}' Note"objectId" is Document Id of Alfresco. |