function startLogin
startLogin(request: FederationLoginRequest): Promise<string>

Starts a sign-in with an account on the instance request.instance names, and returns its /authorize page with the request, for POST /api/federation/logins. Unless that instance is trusted, or someone here already comes from it, the request must carry a valid invite, which is claimed only once the account is made; completeLogin makes no account without one.

Parameters

Return Type

Promise<string>

Throws

APIException

400 when the instance isn't one; 403 when sign-ins from other instances are off, or it is blocked, neither trusted nor invited, or keeps its users from signing in elsewhere; 404 or 409 when the invite doesn't work; 502 when it doesn't answer as a gerbeur.

Usage

import { startLogin } from "api/services/federation-service.ts";