Skip to main content

 Services

Web services from /about to /webhooks

Oauth clients

/oauth/members/{member}/clients [POST]

Description

Create an OAuth client.

In practice the scope parameter must be specified, otherwise client access is limited to services like get self.

Parameters

NameDescriptionRequiredTypeDefault value
nameThe name of the client (informational)yesstring
app
The name of the app (informational)nostring
access-token-max-ageThe max age of the access tokens in secondsnolong1 hour
client-secretThe client secretnostring[random string]
client-uriThe URL for the client app (informational)nostring
confidentialWhether the client is capable of maintaining confidentiality of credentialsnobooleantrue
descriptionThe description of this client (informational)nostring
grant-typeThe grant type allowed for this client:
[authorization_code|password|client_credentials]
nostringauthorization_code
identifierThe OAuth 2.0 client ID - 16 digit hexadecimal number (admin only)nostring[random hex number]
redirect-uriThe redirection URI specific to this clientnourl
refresh-token-max-ageThe max age of the refresh tokens in secondsnolong30 days
scopeA space separated list of scopes allowed for this client e.g. openid
profile email
nostring
webhook-secretThe secret used for signing webhook requests (between 24 and 64 characters long)nostring

Permission

The member themselves or an administrator.

Response

<client-registration>
  <client id="1"
          identifier="2aa92c5a79baf3fe"
          requires-consent="false"
          confidential="false"
          name="My app"
          grant-type="authorization_code"
          [created="2020-03-08T12:34:00+10:00"]
          [modified="2020-03-10T11:24:00+10:00"]
          [last-token="2020-05-10T10:28:00+10:00"]
          [app="Timesheet"]
          [webhook-secret="S0meP@ssw0d"]
          [redirect-uri="http://example.org/login"]
          [description="My example timesheet"]
          [client-uri="http://example.org"]
          [scope="openid profile email"]
          access-token-max-age="7200"
          refresh-token-max-age="0">
    <member id="45" ...>
      <fullname>John Smith</fullname>
    </member>
  </client>
</client-registration>

Error Handling

Error codes
CodeCause / Description
0x1041Maximum number of clients for this member has been reached
0x1042Maximum number of clients for server has been reached
0x1043Client name or identifier already in use
0x1044Identifier must be a 16 digit hexadecimal number
0x1045Malformed redirect URI
0x1047Invalid grant type
0x1048Invalid scope
0x1049The webhook-secret must be between 24 and 64 characters
0x104APublic clients cannot use the client_credentials grant type
Created on , last edited on