---
title: "Company Register Social"
method: POST
path: "/companies/register-social"
tags: ["COMPANY"]
---

# Company Register Social

`POST /companies/register-social`

Provision a new tenant for a socially-authenticated (Google) user.

Runs on the public tenant against a verified SuperTokens session — the user
has already completed Google OAuth and passed the Workspace `hd` gate in the
sign-in-up hook. Email comes from the session (never from the client); only
the instance name (and optional display name) come from the request.
Creates the tenant + Owner + billing + community credits and returns the
gateway credential. If the instance name is taken, returns
``status="instance_taken"`` so the UI can re-prompt.

## Request body

- SocialRegisterIn — Provision a new tenant for a socially-authenticated (OAuth) user. Email is taken from the verified SuperTokens session; the client supplies the chosen instance name and, optionally, the display name read from the OAuth profile (falls back to the email local-part when absent).
  - `company` string, required
  - `newsletter` boolean
  - `first_name` string, nullable
  - `last_name` string, nullable
  - `source_insight` string, nullable
  - `referral_code` string, nullable
  - `survey_responses` object, nullable
  - `primary_warehouse` string, nullable
  - `role` string, nullable

## Response `200`

Successful Response

- SocialRegisterResponse — Result of provisioning a tenant for a social (OAuth) signup. On success, carries a short-lived ``login_token`` the client exchanges (via /auth/social/exchange) for the gateway credential — the raw api_key is never returned to the client. When the chosen instance name is taken (or belongs to an instance running its own IdP), ``status == "instance_taken"`` and the fields are null so the UI can re-prompt — the two negatives are intentionally indistinguishable so the response can't enumerate SSO instances.
  - `status` 'ok' | 'instance_taken', required
  - `instance` string, nullable
  - `api_url` string, nullable
  - `login_token` string, nullable

## Other responses

- `400` — Bad request.
- `403` — Forbidden in the tenant domain.
- `422` — Validation Error

---

[API](https://skmtc.net/myaltimate/apis/fastapi.md) · [All operations](https://skmtc.net/myaltimate/apis/fastapi/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/myaltimate/fastapi/versions/aab3fe5c9f05/schema)
