Skip to Main Content

405 response when using the jobs Planning API Resource

DesmondJun 6 2021

Hello I am trying to use the jobs API resource as below in Python but I keep getting a 404 response status. Can you please tell me what I am missing ?
import requests
username = '<user name>'
password = '<password>'
iddomain = 'annnnnnn'
serv_url = 'https://epm11-test-' + iddomain + '.epm.ap1.oraclecloud.com
session = requests.Session()
session.auth = (iddomain + '.' + username, password)
application = '<PBCS App Name>'
payload = {'jobType':'Rules','jobName':'<Business Rule Name>'}
headers = {'Content-Type': 'application/json'}
api = f'/HyperionPlanning/rest/v3/applications/{application}/jobs'
r = session.post(serv_url + api, headers=headers, data=payload)
print (r.status_code)

I can successfully upload a data file and update substitution variables but I can't get the job API resource to work.

Any pointers , guesses as to what I could try would help.

Thanks !

Comments
Post Details
Added on Jun 6 2021
0 comments
32 views