Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

This section explains the following REST operations regarding the collection which have been secured with OAuth 2.0.

  • Get the content of a collection.
  • Add a collection
  • Delete a given collection

Get the content of a collection

AttributesValues
HTTP MethodGET
Request URI http://<ip address>:<port>/restapi/resource/<collection path>
HTTP Request HeaderAuthorization: Bearer <OAuth access token>
Response                      Content of the requested collection
Response TypeJSON

Add a resource

Attributesvalues
HTTP MethodPUT
Request URIhttp://<ip address>:<port>/restapi/resource/<complete path of the collection to be added>
HTTP Request HeaderAuthorization: Bearer <OAuth access token>
Request Content Typeapplication/collection
Response204 No Content - if Success/ 401 - if fails

Delete a resource

Attributesvalues
HTTP MethodDELETE
Request URI http://<ip address>:<port>/restapi/resource/<collection path>
HTTP Request HeaderAuthorization: Bearer <OAuth access token>
Response204 No Content - if success/ 401 - if fails.
Note

Please note the following points for the above requests.

  • ip address -IP address at which Governance Registry is running
  • port - HTTP port number at the Governance Registry is up
  • collection path - Path of the collection
  • OAuth access token - Authorized access token per user for an hour by default.
  • restapi - name of the War file for the REST API resides at {Greg_home}/repository/deployment/server/jaxwebapps. If the user renamed this war file,
    the new name value will be used instead of restapi.
  • MIME media type - mime type of resource to be added. eg:- application/wsdl+xml media type for WSDL files.