OAuth
Authorizations
AuthorizationstringRequired
OAuth2 Bearer token obtained from authentication endpoint
Body
orgIdinteger · int32OptionalExample:
Organization ID, in which OAuth client will be created. If not provided, the organization, that is associated with the authentication token, will be used.
101namestring · min: 1 · max: 64RequiredExample:
Client application name
My IoT AppredirectUrlsstring · uri[] · max: 10OptionalExample:
Redirect URIs
https://myapp.com/oauth/callbackResponses
201
OAuth client created successfully
application/json
orgIdinteger · int32RequiredExample:
Organization ID, that the client belongs to
101namestringRequiredExample:
Client application name
My IoT AppclientIdstringRequiredExample:
OAuth client ID
oa2-client-id_s5XUlzvfaQL8BVkteN6DuIdUxdX7u0lJsecretstringRequiredExample:
OAuth client secret
xDG7p4mu4J37P4aoa0TXCFr1hii35j_775S-2dKsredirectUrlsstring[]OptionalExample:
Allowed redirect URIs
https://myapp.com/oauth/callback400
Bad request
application/json
403
Forbidden
application/json
404
Organization not found or access denied
application/json
429
Too many requests
500
Internal server error
application/json
post/api/v1/organization/oauth/clients/create
POST /api/v1/organization/oauth/clients/create HTTP/1.1
Host: blynk.cloud
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 151
{
"orgId": 101,
"name": "My IoT App",
"redirectUrls": [
"https://myapp.com/oauth/callback"
],
"scopes": [
"PLATFORM_API",
"CLIENT_CREDENTIALS",
"DEVICES_GET_ONLY"
]
}{
"orgId": 101,
"name": "My IoT App",
"clientId": "oa2-client-id_s5XUlzvfaQL8BVkteN6DuIdUxdX7u0lJ",
"secret": "xDG7p4mu4J37P4aoa0TXCFr1hii35j_775S-2dKs",
"redirectUrls": [
"https://myapp.com/oauth/callback"
],
"scopes": [
"PLATFORM_API"
]
}Last updated
Was this helpful?

