Integrations
Preview

Link a GitHub login to a member

Says the login is that member, replacing what it was linked to. Pushes by the login from now on are raised by the member. Writes an Activity entry. Needs `integration:manage`, since the link decides who may not approve what.

PUT
/github/logins/{login}
cookiebetter-auth.session_token<token>

Better Auth session cookie. Production uses the __Secure- prefixed name.

login*string

A GitHub login. It is not told apart by case.

Lengthlength <= 39
Idempotency-Key?string

Makes retries safe. A repeated key with the same request returns the first result and sets Idempotent-Replayed: true. The same key with a different request answers 409 idempotency.key_reused, and while the first request is still running 409 idempotency.in_progress. Results are kept for 24 hours. Server errors and refusals for lack of sign-in or permission are not kept, so a retry runs again.

Match^[A-Za-z0-9_.:-]+$
Length1 <= length <= 255
application/json
  1. body
userId*string

The member the login is.

Response Body

The link.

application/json
  1. response
login*string
userId*string
linkedBy*string
linkedAt*string
Formatdate-time
Example Request
curl -X PUT 'https://wardn.example.com/api/v1/github/logins/string' \  -H 'Content-Type: application/json' \  -d '{  "userId": "string"}'
Example Response
{  "login": "string",  "userId": "string",  "linkedBy": "string",  "linkedAt": "2019-08-24T14:15:22Z"}