Description
You have to call this method when you want to create a new wApp in DRUID Identity allowing you to automatise integrations with us.
You will get all the information of the app (and entrypoint(s) created), as well as the password we have generated for you.
Be careful, because the password will only be returned once in the response, and if you need to consult it later, you must do it through the Cockpit.
Please, read first: https://dru-id.com/developers/apis/oauth-2/ to learn about Oauth2 protocol and the meaning of each token.
Endpoint URL:
POST https://graph.{your-domain.com}/v2/apps
Request headers
Header | Description | Type | Required | Value |
---|---|---|---|---|
Authorization | Bearer {{app_token}} Literal text Bearer followed by app_token that is the token returned by auth server with client_credentials flow | string | yes | Bearer {{app_token}} |
Content-Type | The type of content that will be used for requests to be JSON | string | yes | application/json |
Accept-Language | Language of this request | Locale | no |
Request example
Path | Description | Type | Required | Value |
---|---|---|---|---|
objectType | Object type of application | string | yes | application |
key | Optional suffix of the id (client_id) of new app. WE will generate Ana aleatory numeric id and append you suffix: {generated-id}_{suffix} | string | no | |
displayName | App Name (human friendly) | string | yes | |
url | Url of web site of this App | string | yes | |
contact.support.objectType | ObjectType of contact structure | string | yes | person |
contact.support.schemaOrg.email.value | Support email | string | yes | |
contact.support.schemaOrg.mobile.value | Support mobile | string | yes | |
contact.projectManager.objectType | ObjectType of contact structure | string | yes | person |
contact.projectManager.schemaOrg.email.value | PM email | string | yes | |
contact.productOwner.objectType | ObjectType of contact structure | string | yes | person |
contact.productOwner.schemaOrg.email.value | PO email | string | yes | |
redirectUris | array with one or more redirect Uris for this app | array[string] | yes | |
organizationSchemaOrg.identifier | key of DruID Organisational Unit associated to this App (ask to DruID to give you this value) | string | yes | |
organizationSchemaOrg.brand | Brand key associated to this App (ask to DruID to give you this value) | string | no | |
schemaOrg.applicationCategory | Property Name associated to this App (ask to DruID to give you this value) | String | no | |
entrypoints.0.objectType | Object type of entrypoint | string | yes | entrypoint |
entrypoints.0.displayName | Entrypoint Name (human friendly) | string | yes | |
entrypoints.0.key | Optional suffix of the id of new entrypoint. We will append your suffix with app key: {client_id}_{suffix} | string | no | |
entrypoints.0.assisted | The registration of consumers through this entrypoint is done through a third party. | boolean | no | default:false |
entrypoints.0.fields.0.objectType | Object type of field | string | yes | fieldConfig |
entrypoints.0.fields.0.type | Type of field, id if field key is email, phone_number (mobile), national_id, screen_name (fields that only allow 1 instance in database) | id | field | yes | id |
entrypoints.0.fields.0.key | key of id | email, phone_number (mobile), national_id, screen_name | yes | |
entrypoints.0.fields.0.main | this id will be used as main contact channel. if multiple id are used in entrypoint, one MUST me main, and therefore will be mandatory=true and requiresConfirmation=true | boolean | yes | |
entrypoints.0.fields.0.mandatory | field is mandatory and must be filled by consumer in form | boolean | yes | |
entrypoints.0.fields.0.requiresConfirmation | this id requires confirmation (true only valid for email, phone_number | boolean | yes | |
entrypoints.0.fields.0.requiresVerification | this id requires verification (true only valid for national_id if you purchase Identity with FacePhi platform) | boolean | no | default:false |
entrypoints.0.fields.1.objectType | Object type of field | string | yes | fieldConfig |
entrypoints.0.fields.1.type | Type of field, in this example will be field (name, surname, birthday, …) | string | yes | field |
entrypoints.0.fields.1.key | key of field to use (one of existing in Identity) | string | yes | |
entrypoints.0.fields.1.mandatory | field is mandatory and must be filled by consumer in form | boolean | no | default: true |
entrypoints.0.fields.1.useForValidation | if entrypoint is created as 2 steps and set to true, consumer will be asked for the value filled in the first step when clicking on the email button as a form of additional validation. | boolean | no | default: false |
entrypoints.0.fields.1.step | if entrypoint is created as 2 steps , this value will define step where field is requested to consumer | integer | no | default: 1 |
entrypoints.0.passwordless | ifs true, this entrypoint des not request password for consumer | boolean | no | false |
entrypoints.0.typology.register.objectType | Object type of typology | string | yes | typology |
entrypoints.0.typology.register.id | id of typology for registration | string | no | default: consumer |
entrypoints.0.typology.work.objectType | Object type of typology | string | yes | typology |
entrypoints.0.typology.work.id | id of typology of work | string | no | default: value of typology.register.id |
Response examples
Response: App created successfully
Response codes
Code | Type | Description |
---|---|---|
201 | Sucess | App created |
400 | Error | Bad Request: The request could not be understood by the server due to malformed syntax |
401 | Error | Unauthorized: authentication is required and has failed or has not yet been provided (token is invalid, etc) |
403 | Error | Forbidden: user id or password are invalid |
500 | Error | Internal Server Error: The server encountered an unexpected condition which prevented it from fulfilling the request |