OAuth2 plugin
QorusOAuth2RestApi::OAuth2ClientsRestClass Class Reference
Inheritance diagram for QorusOAuth2RestApi::OAuth2ClientsRestClass:

Public Member Functions

string name ()
 
__7_ AbstractRestClass subClass (string arg, hash< auto > cx, __7_ hash< auto > ah)
 
hash< auto > post (hash< auto > cx, __7_ hash< auto > ah)
 
hash< auto > get (hash< auto > cx, __7_ hash< auto > ah)
 

Detailed Description

/oauth2/v1/clients

This REST URI path provides actions and information about OAuth2 clients

Member Function Documentation

◆ get()

hash<auto> QorusOAuth2RestApi::OAuth2ClientsRestClass::get ( hash< auto >  cx,
__7_ hash< auto >  ah 
)
inline

GET

Description
Returns information about OAuth2 clients registered in Qorus. If username is among the parameters, only clients registered for that user are returned.
Return Value
This API returns a list of hashes with the following keys:
  • client_id: (string) unique identifier of the client
  • username: (string) user associated with the client
  • created: (date) date of record creation
  • modified: (date) date of record last modification

◆ post()

hash<auto> QorusOAuth2RestApi::OAuth2ClientsRestClass::post ( hash< auto >  cx,
__7_ hash< auto >  ah 
)
inline

POST

Description
Inserts OAuth2 client data in DB
Arguments
This API takes the following hash arguments (either as URI arguments or in the message body):
  • client_id: (string) unique identifier of the client
  • client_secret: (string) secret associated with the client
  • username: (string) user associated with the client
  • permissions: (list) list of permissions
Return Value
This API returns a hash with the following keys:
  • inserted: (hash) hash with informataion about inserted client
    • client_id: (string) unique identifier of the client
    • username: (string) user associated with the client
    • created: (date) date of record creation
    • modified: (date) date of record las modification
Errors
  • 409 Conflict: OAUTH2-EXCEPTION: this exception is thrown when any error occurs while inserting the data. More error description is part of the response.

The documentation for this class was generated from the following file: