Missed Team ’24? Catch up on announcements here.

×
Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Call new Insight JSM rest api

Folino August 3, 2021

Hello
I’ve been trying to follow the explaination to make rest api in new JSM Insight as described here
https://developer.atlassian.com/cloud/insight/intro/introduction-and-basics/

I’ve achieved to get the workspaceId as i put on the code

base_url = "https://mybaseUrl.net"
workSpace = "/rest/servicedeskapi/insight/workspace"
headers = {"Accept":"application/json","X-ExperimentalApi" : "opt-in"}
auth = HTTPBasicAuth("simone.folino@sourcesense.com","****************")
workspace2 = json.loads(requests.get(f"{base_url}{workSpace}",headers=headers,auth=auth).text)
workspaceId = workspace2['values'][0]['workspaceId']
# Out[103]: 'my workspaceId'
icon_rest = f"/jsm/insight/workspace/{workspaceId}/v1/icon/global"
requests.get(f"{base_url}{icon_rest}",headers={"Accept":"application/json"}).text

However, when I try to call the /jsm/insight/workspace/{workspaceId}/v1/icon/global it gives me a dead link.
Am Idoing something wrong?

Thank you in Advance,
Simone

1 answer

0 votes
Victor Tseng
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
November 11, 2021

Hi @Folino

We are also hitting this issue when we try to use the REST API in Cloud version of Insight. BTW the API URL structure looks different from the DC/Server version. Hopefully there could be some more details about how exactly these URL paths should be...

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events