Skip to content

Start connecting Google or Apple​

POST
/cognito/sign-in-methods/{provider}/connect

Opens a round trip that connects Google or Apple to the signed-in account, and answers the address to open in the provider window. The round trip ends at GET /cognito/oauth/callback, which redirects to returnPath with connect_provider and connect_result; the browser stays signed in as it was.

A provider connects only when the provider account uses the account's own sign-in address, and that address is verified. This is the rule sign-in already links by; another address is refused (email_mismatch) and no account is created for it.

The response sets the short-lived httpOnly oauth_flow cookie the callback requires, so the provider window must be opened by the same browser. One round trip per account is open at a time, each lasts ten minutes, and an account may start ten an hour. A completed connect is written to the audit log and the account's owner is emailed a security notice.

Needs a real sign-in session: not an API key, and not an admin acting as the user. Rate limited at 30 requests/minute per account and 60 per IP.

Authorizations​

BearerAuth

In the browser, authentication rides on the httpOnly session cookies set by /cognito/signin or the Google / Apple sign-in at /cognito/oauth/{provider}. For scripts and for Swagger UI testing, paste an API key (fh_live_…, created with POST /api-keys); a Cognito JWT is accepted too. Sign-in does not return a token in its body.

Type
HTTP (bearer)

Parameters​

Path Parameters

provider*
Type
string
Required
Valid values
"google""apple"

Request Body​

application/json
JSON
{
"returnPath": "string"
}

Responses​

The round trip is open

application/json
JSON
{
"provider": "string",
"authorizeUrl": "string",
"expiresInSeconds": 0
}

Playground​

Server
Authorization
Variables
Key
Value
Body

Samples​

Powered by VitePress OpenAPI

Built with VitePress