How To Move Policy Project From Dev To PROD Using REST API
(Doc ID 2823965.1)
Last updated on AUGUST 15, 2023
Applies to:
Oracle Communications Cloud Native Core - 5G - Version Core 2.4.0 and laterInformation in this document applies to any platform.
Goal
Please cloud you help us to move the policy project from dev to prod using API .
We have referred the Release 1.14.0 F45498-01 Cloud Native Core Policy REST Specification Document.
In the process , we were trying the only suitable API but we are running into error , may be we are missing something .
page 2-143...table 2-147
Update Policy Project State | PUT | {apiRoot}/oc-cnpolicyconfiguration/v1/policymgmt/policyprojects/{serviceName}/{policyProjectName}
Below is the Curl command
curl -v -X PUT http://{apiRoot}/oc-cnpolicy-configuration/v1/policymgmt/policyprojects/pcf-sm/5GTesting
[sct612@pc001tools01 ~]$ curl -v -X PUT http://{apiRoot}/oc-cnpolicy-configuration/v1/policymgmt/policyprojects/pcf-sm/5GTesting
* Trying aa.bb.cc.dd...
* TCP_NODELAY set
* Connected to {apiRoot} (aa.bb.cc.dd) port 80 (#0)
> PUT /oc-cnpolicy-configuration/v1/policymgmt/policyprojects/pcf-sm/5GTesting HTTP/1.1
> Host: {apiRoot}
> User-Agent: curl/7.61.1
> Accept: */*
>
< HTTP/1.1 400 Bad Request
< Server: nginx/1.19.2
< Date: Wed, 24 Nov 2021 14:23:34 GMT
< Content-Type: application/json
< Transfer-Encoding: chunked
< Connection: keep-alive
<
* Connection #0 to host {apiRoot} left intact
{"status":"BAD_REQUEST","timestamp":"2021-11-24T14:23:34Z","message":"Malformed Json request"}
[sct612@pc001tools01 ~]$ curl -v -X PUT http://{apiRoot}/oc-cnpolicy-configuration/v1/policymgmt/policyprojects/pcf-sm/5GTesting
* Trying aa.bb.cc.dd...
* TCP_NODELAY set
* Connected to {apiRoot} (aa.bb.cc.dd) port 80 (#0)
> PUT /oc-cnpolicy-configuration/v1/policymgmt/policyprojects/pcf-sm/5GTesting HTTP/1.1
> Host: {apiRoot}
> User-Agent: curl/7.61.1
> Accept: */*
>
< HTTP/1.1 400 Bad Request
< Server: nginx/1.19.2
< Date: Wed, 24 Nov 2021 14:23:34 GMT
< Content-Type: application/json
< Transfer-Encoding: chunked
< Connection: keep-alive
<
* Connection #0 to host {apiRoot} left intact
{"status":"BAD_REQUEST","timestamp":"2021-11-24T14:23:34Z","message":"Malformed Json request"}
Solution
To view full details, sign in with your My Oracle Support account. |
|
Don't have a My Oracle Support account? Click to get started! |
In this Document
Goal |
Solution |