Search + K

Command Palette

Search for a command to run...

Sign In

Add social accounts for the authenticated user

POST /user/social_accounts
Copy endpoint
https://api.github.com

Add one or more social accounts to the authenticated user's profile.

OAuth app tokens and personal access tokens (classic) need the user scope to use this endpoint.

Request Body

application/json required
{ account_urls: string[]; }

Responses

201 application/json

Response

interface SocialAccount {
provider: string;
url: string;
}
[]

Redirects

304

Not modified

unknown

Client Errors

401 application/json

Requires authentication

interface BasicError {
message?: string;
documentation_url?: string;
url?: string;
status?: string;
}
403 application/json

Forbidden

interface BasicError {
message?: string;
documentation_url?: string;
url?: string;
status?: string;
}
404 application/json

Resource not found

interface BasicError {
message?: string;
documentation_url?: string;
url?: string;
status?: string;
}
422 application/json

Validation failed, or the endpoint has been spammed.

interface ValidationError {
message: string;
documentation_url: string;
errors?: {
resource?: string;
field?: string;
message?: string;
code: string;
index?: number;
value?: string[] | string | number | null;
}
[]
;
}