GET /api/apis/versions/{APIVersionID}/viewers/{ViewerID}/scope

Returns information about scope visibility for a specific API version, for a specific viewer.

Authorization Roles/Permissions: Must have Read permission for the resource.

This topic includes the following sections:

HTTP Method

GET

Back to top

URL

https://{hostname}/api/apis/versions/{APIVersionID}/viewers/{ViewerID}/scope

Back to top

Sample Request

The example below shows a request for the private viewer scope for the specified API version, specified user.

Request URL

https://{hostname}/api/apis/versions/a1fa6440-8fa6-4453-a0a0-4db181ab1512.acmepaymentscorp/viewers/5a462990-fbb4-40e0-908e-0246119fe7e0.acmepaymentscorp/scope

Sample request headers

Accept: application/json
X-Csrf-Token_{tenant}: {TokenID}

Sample request body

Not applicable.

Back to top

Request Headers

For general information on request header values, refer to HTTP Request Headers.

Header Description
Accept

application/json, application/xml

application/vnd.soa.v71+json, application/vnd.soa.v71+xml

application/vnd.soa.v72+json, application/vnd.soa.v72+xml

application/vnd.soa.v80+json, application/vnd.soa.v80+xml

application/vnd.soa.v81+json, application/vnd.soa.v81+xml

Back to top

Request Parameters

Parameter Parm Type Data Type Required Description
APIVersionID Path string Required The unique ID for a specific API version.
ViewerID Path string Required The GroupID of a group that has visibility into the API.

Back to top

Response

If successful, this operation returns HTTP status code 200, with information about whether the specified viewer has private viewer scope to the specified API version.

Back to top

Sample Response

The sample response below shows successful completion of this operation. The specified viewer does not have restricted scope for the specified API version.

Sample response headers: application/json

Status Code: 200 OK
Content-Type: application/json
Expires: Wed, 11 Jun 2014 10:20:37 GMT

Sample response body: application/json

{
  "ResourceID" : "5e844469-8bf4-4d16-adc3-00fdf6e56a12.acmepaymentscorp",
  "ResourceType" : "apiversion",
  "ViewerID" : "apiadmin-73691c5e-598a-4251-aac2-2a5b28385207.acmepaymentscorp",
  "ViewerType" : "group",
  "RestrictedScope" : false
}

Back to top

Sample response headers: application/xml

Content-Type: application/xml

Sample response body: application/xml

<?xml version="1.0" encoding="UTF-8"?>
<VisibilityContractDetails xmlns="http://soa.com/xsd/resource/1.0" xmlns:ns2="http://soa.com/xsd/user/1.0" 
xmlns:ns3="http://soa.com/xsd/business/1.0" xmlns:ns4="http://soa.com/xsd/legals/1.0">
  <ResourceID>5e844469-8bf4-4d16-adc3-00fdf6e56a12.acmepaymentscorp</ResourceID>
  <ResourceType>apiversion</ResourceType>
  <ViewerID>apiadmin-73691c5e-598a-4251-aac2-2a5b28385207.acmepaymentscorp</ViewerID>
  <ViewerType>group</ViewerType>
  <RestrictedScope>false</RestrictedScope>
</VisibilityContractDetails>

Back to top

Response Headers

For general information on response header values, refer to HTTP Response Headers.

Header Description
Content-Type

application/json, application/xml

application/vnd.soa.v71+json, application/vnd.soa.v71+xml

application/vnd.soa.v72+json, application/vnd.soa.v72+xml

application/vnd.soa.v80+json, application/vnd.soa.v80+xml

application/vnd.soa.v81+json, application/vnd.soa.v81+xml

Back to top

Response Body

Name Type Description
VisibilityContractDetails VisibilityContractDetails Contains information about a viewer's visibility of a specific resource.

Back to top

Error Codes/Messages

If the call is unsuccessful an error code/message is returned. One or more examples of possible errors for this operation are shown below.

Item Value
400 Returned if the client sends invalid parameters or body content. For example, you might get this response if you forgot to replace a variable in the request URL with a valid value.
401 Unauthorized. For example, you would get this response if you didn't include the custom X-Csrf-Token_{fedmemberID} header in the request, when it was required by the platform settings; or if you included an invalid or expired value for this header.
500 An error occurred processing the call.

More information about Akana API Platform API error messages.

Back to top

Related Topics