1. Docs
  2. API Reference
  3. OAuth hosted login: continue with a social provider

OAuth hosted login: continue with a social provider

POST/oauth/social/{provider}/start

A provider button on the hosted sign-in or sign-up page posts the authorization request here, with page naming the page it is on. Checks the request as /oauth/authorize does, then redirects the browser to the provider with the request kept server-side and PKCE, state and nonce of Canopy's own. The provider answers at /v1/identity/auth/social/:provider/callback, which resumes the request on the origin it started on through /oauth/sso/continue: the organization's policy, the second factor and the code follow as for any hosted sign-in. A provider the Environment has not enabled, or one that cannot be reached, is a refusal shown on the page the sign-in started from. Works without JavaScript.

Path Parameters

providerstring Required

Request body

application/json

client_idstring Required
redirect_uristring Required
response_typestring Required
scopestring Required
statestring Optional
code_challengestring Required
code_challenge_methodstring Required
noncestring Optional
organizationstring Optional
pageenum Optional

The page the button is on, where a refused sign-in is shown. Defaults to the sign-in page.

one of "sign_in" · "sign_up"

Responses

A redirect to the provider's sign-in; or, when the provider is not enabled or cannot be reached, to `/oauth/sso/continue`, which shows the page the sign-in started from with the reason

application/json

  • errorApiErrorBodyDto*

application/json

  • errorApiErrorBodyDto*

Rate limit

20 requests per 1mPer caller: the signed-in user for a bearer token; for an API key, the key and the end user's address when a backend forwards it, otherwise the client address
Request
curl -X POST "https://auth.canopy-io.com/oauth/social/value/start" \
  -H "Content-Type: application/json" \
  -d '{
    "client_id": "string",
    "redirect_uri": "string",
    "response_type": "string",
    "scope": "string",
    "state": "string",
    "code_challenge": "string",
    "code_challenge_method": "string",
    "nonce": "string",
    "organization": "string",
    "page": "sign_in"
  }'
Response
HTTP/1.1 302 A redirect to the provider's sign-in; or, when the provider is not enabled or cannot be reached, to `/oauth/sso/continue`, which shows the page the sign-in started from with the reason

(empty body)
Related endpoints Was this page helpful?

Tell us how we can improve this guide.