Commit 65ce2e57 authored by Bobby Rullo's avatar Bobby Rullo

schema: update schema docs

parent 41740179
...@@ -28,14 +28,14 @@ __Version:__ v1 ...@@ -28,14 +28,14 @@ __Version:__ v1
{ {
clientName: string // OPTIONAL for normal cliens. Name of the Client to be presented to the End-User. If desired, representation of this Claim in different languages and scripts is represented as described in Section 2.1 ( Metadata Languages and Scripts ). REQUIRED for public clients, clientName: string // OPTIONAL for normal cliens. Name of the Client to be presented to the End-User. If desired, representation of this Claim in different languages and scripts is represented as described in Section 2.1 ( Metadata Languages and Scripts ). REQUIRED for public clients,
clientURI: string // OPTIONAL. URL of the home page of the Client. The value of this field MUST point to a valid Web page. If present, the server SHOULD display this URL to the End-User in a followable fashion. If desired, representation of this Claim in different languages and scripts is represented as described in Section 2.1 ( Metadata Languages and Scripts ) ., clientURI: string // OPTIONAL. URL of the home page of the Client. The value of this field MUST point to a valid Web page. If present, the server SHOULD display this URL to the End-User in a followable fashion. If desired, representation of this Claim in different languages and scripts is represented as described in Section 2.1 ( Metadata Languages and Scripts ) .,
id: string // The client ID. Ignored in client create requests., id: string // The client ID. If specified in a client create request, it will be used as the ID. Otherwise, the server will choose the ID.,
isAdmin: boolean, isAdmin: boolean,
logoURI: string // OPTIONAL. URL that references a logo for the Client application. If present, the server SHOULD display this image to the End-User during approval. The value of this field MUST point to a valid image file. If desired, representation of this Claim in different languages and scripts is represented as described in Section 2.1 ( Metadata Languages and Scripts ) ., logoURI: string // OPTIONAL. URL that references a logo for the Client application. If present, the server SHOULD display this image to the End-User during approval. The value of this field MUST point to a valid image file. If desired, representation of this Claim in different languages and scripts is represented as described in Section 2.1 ( Metadata Languages and Scripts ) .,
public: boolean // OPTIONAL. Determines if the client is public. Public clients have certain restrictions: They cannot use their credentials to obtain a client JWT. Their redirects URLs cannot be specified: they are always http://localhost:$PORT or urn:ietf:wg:oauth:2.0:oob, public: boolean // OPTIONAL. Determines if the client is public. Public clients have certain restrictions: They cannot use their credentials to obtain a client JWT. Their redirects URLs cannot be specified: they are always http://localhost:$PORT or urn:ietf:wg:oauth:2.0:oob.,
redirectURIs: [ redirectURIs: [
string string
], ],
secret: string // The client secret. Ignored in client create requests., secret: string // The client secret. If specified in a client create request, it will be used as the secret. Otherwise, the server will choose the secret. Must be a base64 URLEncoded string.,
trustedPeers: [ trustedPeers: [
string string
] ]
......
...@@ -125,7 +125,8 @@ type Client struct { ...@@ -125,7 +125,8 @@ type Client struct {
// Languages and Scripts ) . // Languages and Scripts ) .
ClientURI string `json:"clientURI,omitempty"` ClientURI string `json:"clientURI,omitempty"`
// Id: The client ID. Ignored in client create requests. // Id: The client ID. If specified in a client create request, it will
// be used as the ID. Otherwise, the server will choose the ID.
Id string `json:"id,omitempty"` Id string `json:"id,omitempty"`
IsAdmin bool `json:"isAdmin,omitempty"` IsAdmin bool `json:"isAdmin,omitempty"`
...@@ -141,7 +142,7 @@ type Client struct { ...@@ -141,7 +142,7 @@ type Client struct {
// Public: OPTIONAL. Determines if the client is public. Public clients // Public: OPTIONAL. Determines if the client is public. Public clients
// have certain restrictions: They cannot use their credentials to // have certain restrictions: They cannot use their credentials to
// obtain a client JWT. Their redirects URLs cannot be specified: they // obtain a client JWT. Their redirects URLs cannot be specified: they
// are always http://localhost:$PORT or urn:ietf:wg:oauth:2.0:oob // are always http://localhost:$PORT or urn:ietf:wg:oauth:2.0:oob.
Public bool `json:"public,omitempty"` Public bool `json:"public,omitempty"`
// RedirectURIs: REQUIRED for normal clients. Array of Redirection URI // RedirectURIs: REQUIRED for normal clients. Array of Redirection URI
...@@ -154,7 +155,9 @@ type Client struct { ...@@ -154,7 +155,9 @@ type Client struct {
// clients. // clients.
RedirectURIs []string `json:"redirectURIs,omitempty"` RedirectURIs []string `json:"redirectURIs,omitempty"`
// Secret: The client secret. Ignored in client create requests. // Secret: The client secret. If specified in a client create request,
// it will be used as the secret. Otherwise, the server will choose the
// secret. Must be a base64 URLEncoded string.
Secret string `json:"secret,omitempty"` Secret string `json:"secret,omitempty"`
// TrustedPeers: Array of ClientIDs of clients that are allowed to mint // TrustedPeers: Array of ClientIDs of clients that are allowed to mint
......
...@@ -58,11 +58,11 @@ const DiscoveryJSON = `{ ...@@ -58,11 +58,11 @@ const DiscoveryJSON = `{
"properties": { "properties": {
"id": { "id": {
"type": "string", "type": "string",
"description": "The client ID. Ignored in client create requests." "description": "The client ID. If specified in a client create request, it will be used as the ID. Otherwise, the server will choose the ID."
}, },
"secret": { "secret": {
"type": "string", "type": "string",
"description": "The client secret. Ignored in client create requests." "description": "The client secret. If specified in a client create request, it will be used as the secret. Otherwise, the server will choose the secret. Must be a base64 URLEncoded string."
}, },
"isAdmin": { "isAdmin": {
"type": "boolean" "type": "boolean"
...@@ -95,7 +95,7 @@ const DiscoveryJSON = `{ ...@@ -95,7 +95,7 @@ const DiscoveryJSON = `{
}, },
"public": { "public": {
"type": "boolean", "type": "boolean",
"description": "OPTIONAL. Determines if the client is public. Public clients have certain restrictions: They cannot use their credentials to obtain a client JWT. Their redirects URLs cannot be specified: they are always http://localhost:$PORT or urn:ietf:wg:oauth:2.0:oob" "description": "OPTIONAL. Determines if the client is public. Public clients have certain restrictions: They cannot use their credentials to obtain a client JWT. Their redirects URLs cannot be specified: they are always http://localhost:$PORT or urn:ietf:wg:oauth:2.0:oob."
} }
} }
}, },
......
...@@ -51,11 +51,11 @@ ...@@ -51,11 +51,11 @@
"properties": { "properties": {
"id": { "id": {
"type": "string", "type": "string",
"description": "The client ID. Ignored in client create requests." "description": "The client ID. If specified in a client create request, it will be used as the ID. Otherwise, the server will choose the ID."
}, },
"secret": { "secret": {
"type": "string", "type": "string",
"description": "The client secret. Ignored in client create requests." "description": "The client secret. If specified in a client create request, it will be used as the secret. Otherwise, the server will choose the secret. Must be a base64 URLEncoded string."
}, },
"isAdmin": { "isAdmin": {
"type": "boolean" "type": "boolean"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment