GET /api/users/{UserID}/apis

Returns information about the APIs that the specified user is connected to, either as an API Administrator or API Scope Group member or as an app team member for an app that's subscribed to the API.

Authorization Roles/Permissions: Must be logged in. Self (logged in) or Site Admin (for any user).

This topic includes the following sections:

HTTP Method

GET

Back to top

URL

https://{hostname}/api/users/{UserID}/apis[?includeVersions=boolean][&start=int]
[&count=int][&VersionCount=int]

Back to top

Sample Request

The example below shows a request for information about APIs the specified user is associated with.

Request URL

https://{hostname}/api/users/522320b9-cb6b-495d-ae07-e4b3bfdb3f6a.acmepaymentscorp/apis

Sample request headers

Accept: application/json

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, text/xml

application/rss+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

X-Csrf-Token_{fedmemberID} The CSRF prevention header; may or may not be required, depending on platform settings. See CSRF Prevention on the Platform. By default, the CSRF header is not required for GET operations and is required for all others, with a few exceptions relating to user login.

Back to top

Request Parameters

Parameter Parm Type Data Type Required Description
UserID Path string Required The unique ID for a specific user.
versionCount Query integer Optional Indicates the number of versions to be included in the results. If not specified, defaults to 0, so versions are not included.

Back to top

Response

If successful, this operation returns HTTP status code 200, with information about the APIs for which the user is an Administrator.

Back to top

Sample Response

The sample response below shows that the specified user has three APIs.

Sample response headers: application/json

Status Code: 200 OK
Content-Type: application/json
Date: Mon, 20 May 2013 23:24:13 GMT

Sample response body: application/json


{
  "channel" : {
    "title" : "My Apis",
    "link" : "../../acmepaymentscorp#/user/522320b9-cb6b-495d-ae07-e4b3bfdb3f6a.acmepaymentscorp/apis",
    "description" : "List of apis by user",
    "item" : [ {
      "title" : "Facepond",
      "description" : "gets you the deals with your facebook likes",
      "category" : [ {
        "value" : "api",
        "domain" : "uddi:soa.com:resourcetype"
      }, {
        "value" : "Limited",
        "domain" : "uddi:soa.com:visibility"
      } ],
      "guid" : {
        "value" : "api12545.acmepaymentscorp"
      },
      "pubDate" : "Wed, 15 Aug 2012 23:47:25 +0000",
      "Rating" : 0.0,
      "Followers" : 0,
      "Image" : {
        "Url" : "https://{hostname}/api/apis/api12545.acmepaymentscorp/avatar"
      },
      "EntityReference" : {
        "Title" : "Facepond (1,0)",
        "Guid" : "apiversion12547.acmepaymentscorp",
        "Category" : [ {
          "value" : "apiversion",
          "domain" : "uddi:soa.com:resourcetype"
        } ]
      },
      "Connections" : 0
    }, {
      "title" : "Reddit",
      "description" : "The reddit API and code are open source.",
      "category" : [ {
        "value" : "api",
        "domain" : "uddi:soa.com:resourcetype"
      }, {
        "value" : "Limited",
        "domain" : "uddi:soa.com:visibility"
      } ],
      "guid" : {
        "value" : "api13350.acmepaymentscorp"
      },
      "pubDate" : "Wed, 19 Dec 2012 11:35:30 +0000",
      "Rating" : 0.0,
      "Followers" : 2,
      "Image" : {
        "Url" : "https://{hostname}/api/apis/api13350.acmepaymentscorp/avatars/751757c08b084c7058acb2984cc1ac9c.png"
      },
      "EntityReference" : {
        "Title" : "Reddit (v1)",
        "Guid" : "apiversion13352.acmepaymentscorp",
        "Category" : [ {
          "value" : "apiversion",
          "domain" : "uddi:soa.com:resourcetype"
        } ]
      },
      "Connections" : 0
    }, {
      "title" : "Linkedin",
      "description" : "Bring user profiles and professional networks to your apps.",
      "category" : [ {
        "value" : "api",
        "domain" : "uddi:soa.com:resourcetype"
      }, {
        "value" : "Public",
        "domain" : "uddi:soa.com:visibility"
      } ],
      "guid" : {
        "value" : "api11135.acmepaymentscorp"
      },
      "pubDate" : "Sat, 20 Apr 2013 05:58:18 +0000",
      "Rating" : 5.0,
      "Followers" : 11,
      "Image" : {
        "Url" : "https://{hostname}/api/apis/api11135.acmepaymentscorp/avatars/751757c08b084c7058acb2984cc1ac9c.png"
      },
      "EntityReference" : {
        "Title" : "Linkedin (1.0)",
        "Guid" : "apiversion11137.acmepaymentscorp",
        "Category" : [ {
          "value" : "apiversion",
          "domain" : "uddi:soa.com:resourcetype"
        } ]
      },
      "Connections" : 11
    } ]
  },
  "version" : "1.0"
}

Back to top

Sample response headers: text/xml

Status Code: 200 OK
Content-Type: text/xml
Date: Mon, 20 May 2013 23:17:40 GMT

Sample response body: text/xml

<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:ns2="http://soa.com/xsd/business/1.0" xmlns:ns3="http://soa.com/xsd/user/1.0" 
xmlns:ns4="http://soa.com/xsd/rss/1.0" xmlns:ns5="http://soa.com/xsd/comment/1.0" 
xmlns:ns6="http://a9.com/-/spec/opensearch/1.1/" xmlns:ns7="http://soa.com/xsd/resource/1.0" 
xmlns:ns8="http://soa.com/xsd/fault/1.0" xmlns:ns9="http://soa.com/xsd/api/1.0" 
xmlns:ns10="http://soa.com/xsd/board/1.0" version="1.0">
  <channel>
    <title>My Apis</title>
    <link>../../acmepaymentscorp#/user/522320b9-cb6b-495d-ae07-e4b3bfdb3f6a.acmepaymentscorp/apis</link>
    <description>List of apis by user</description>
    <item>
      <title>Facepond</title>
      <description>gets you the deals with your facebook likes</description>
      <category domain="uddi:soa.com:resourcetype">api</category>
      <category domain="uddi:soa.com:visibility">Limited</category>
      <guid>api12545.acmepaymentscorp</guid>
      <pubDate>Wed, 15 Aug 2012 23:47:25 +0000</pubDate>
      <ns4:Image>
        <Url>https://{hostname}/api/apis/api12545.acmepaymentscorp/avatar</Url>
      </ns4:Image>
      <ns4:EntityReference>
        <Title>Facepond (1,0)</Title>
        <Guid>apiversion12547.acmepaymentscorp</Guid>
        <ns4:Category domain="uddi:soa.com:resourcetype">apiversion</ns4:Category>
      </ns4:EntityReference>
      <ns4:Connections>0</ns4:Connections>
      <ns4:Followers>0</ns4:Followers>
      <ns4:Rating>0.0</ns4:Rating>
    </item>
    <item>
      <title>Reddit</title>
      <description>The reddit API and code are open source.</description>
      <category domain="uddi:soa.com:resourcetype">api</category>
      <category domain="uddi:soa.com:visibility">Limited</category>
      <guid>api13350.acmepaymentscorp</guid>
      <pubDate>Wed, 19 Dec 2012 11:35:30 +0000</pubDate>
      <ns4:Image>
        <Url>https://{hostname}/api/apis/api13350.acmepaymentscorp/avatars/751757c08b084c7058acb2984cc1ac9c.png</Url>
      </ns4:Image>
      <ns4:EntityReference>
        <Title>Reddit (v1)</Title>
        <Guid>apiversion13352.acmepaymentscorp</Guid>
        <ns4:Category domain="uddi:soa.com:resourcetype">apiversion</ns4:Category>
      </ns4:EntityReference>
      <ns4:Connections>0</ns4:Connections>
      <ns4:Followers>2</ns4:Followers>
      <ns4:Rating>0.0</ns4:Rating>
    </item>
    <item>
      <title>Linkedin</title>
      <description>Bring user profiles and professional networks to your apps.</description>
      <category domain="uddi:soa.com:resourcetype">api</category>
      <category domain="uddi:soa.com:visibility">Public</category>
      <guid>api11135.acmepaymentscorp</guid>
      <pubDate>Sat, 20 Apr 2013 05:58:18 +0000</pubDate>
      <ns4:Image>
        <Url>https://{hostname}/api/apis/api11135.acmepaymentscorp/avatars/751757c08b084c7058acb2984cc1ac9c.png</Url>
      </ns4:Image>
      <ns4:EntityReference>
        <Title>Linkedin (1.0)</Title>
        <Guid>apiversion11137.acmepaymentscorp</Guid>
        <ns4:Category domain="uddi:soa.com:resourcetype">apiversion</ns4:Category>
      </ns4:EntityReference>
      <ns4:Connections>11</ns4:Connections>
      <ns4:Followers>11</ns4:Followers>
      <ns4:Rating>5.0</ns4:Rating>
    </item>
  </channel>
</rss>

Back to top

Response Headers

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

Header Description
Content-Type

application/json, text/xml

application/rss+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

The response body is in the form of an RSS channel, and includes the items listed below. The RSS version is 1.0. The title of the RSS Channel is My Apis, and the channel includes a link to the source of the RSS channel information and a text description of the RSS channel. Each item in the RSS channel represents an API for which the specified user is an administrator, and includes the information below.

Name Description
title The text title of the API.
description Text description of the API.
category[ ]

An array of sets of two name/value pairs, each including Value and Domain, with a value for each. For example:

"value" : "api",
"domain" : "uddi:soa.com:resourcetype"

The example above indicates a resource type of api.

GUID GUID for the API; the APIID.
pubdate The date/timestamp when the API was created.
rating The overall rating for the API.
followers The number of users following the API.
image URL to the API's avatar, if applicable. If the API has no custom avatar, the URL to the default API avatar is included.
Entity reference

An array of one or more entity references for the API, with information about the API versions. Each includes:

  • Title: the title of the API version,
  • GUID: the APIVersionID.
  • Category[ ]: an array of sets of two name/value pairs, each including Value and Domain, with a value for each. For example:

    "value" : "apiversion",
    "domain" : "uddi:soa.com:resourcetype"
    

    The example above indicates a resource type of apiversion.

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
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. You would also get this response for any operation that requires login (almost all) if the login cookie was missing.
500 An error occurred processing the call.

More information about Akana API Platform API error messages.

Back to top

Related Topics