Hi Any python packages for REST API
Hi Any python packages for REST API
In documentation I did see only Java,Javascript and C#
-
正式評論
Udaya,
We do not have any documentation for python. Additionally we have cURL and Swagger.
https://documentation.agilepoint.com/11/developer/restapiOpenSwaggerURL.html.
Thank You
AgilePoint NX Support
評論操作 -
Hi Udaya,
You can use any python REST library of your choosing, either standard or other.
Here is a code snippet sample for CreatePorcInst using the requests libabry:
# Import REST API library (NOTE: you can use any of your choosing)import requests
# Set your AgilePoint env rest endpoint URL# NOTE make sute to use the correct server name and port for your env - you can get it from Portal > Settings > Tenant Settings > Tenant InformationagilePointRestURL = 'https://MyAgilePointServer:13490/AgilePointServer/Workflow/CreateProcInst'# Set the CreateProcInst object and use your values for each of the properties as needed by your app logic.myCreateProcInstOptions = {'ProcessID': '55D6D7F802B5450D95026297ADCAD8C3', # SomeTemplateValue. Can either use TemplateID or Name'ProcessInstID': '0FD3088F40B640D4AFE41AEEBDAE0004', # SomeProcInstIDValue - GUID type value (no braces and hyphens). You can use use uuid.uuid4().hex (import uuid), or you can use AgilePoint REST GetUUID'ProcInstName': 'SomeUniqueProcInstName','WorkObjID': '0FD3088F40B640D4AFE41AEEBDAE0005', # SomeWordObjectIDValueGUID type value (no braces and hyphens). NOT THE SAME as ProcessInstID You can use use uuid.uuid4().hex (import uuid), or you can use AgilePoint REST GetUUID'WorkObjInfo'; null,'SuperProcInstID': null,'Initiator': 'SomeDomain\\SomeUser','CustomID': '0FD3088F40B640D4AFE41AEEBDAE0005', # SomeCustomIDValue. Typically you'll use here the same value used for WorkObjID'Attributes': [{'Name': 'SomeName1', 'Value': 'SomeValue1'}, {'Name': 'SomeName2', 'Value': 'SomeValue2'}],'blnStartImmediately': True}# Call the REST API (post action type)resCreeteProcInst = requests.post(url, data = myCreateProcInstOptions)# Print the result (WFEvent type)print(resCreeteProcInst.text)Hope this helps.Thanks,Yaniv.
請登入寫評論。
評論
2 條評論