Skip to main content
POST
Enable a Chat group invite link

Authorizations

Authorization
string
header
required

The access token received from the authorization server in the OAuth 2.0 flow.

Path Parameters

id
string
required

The ID of the group conversation, starting with g.

Pattern: ^g[0-9]{1,19}$

Body

application/json
action_signatures
object[]

Cryptographic signatures for the action.

affiliate_user_id
string

ID of the affiliate account to associate with the link.

Pattern: ^[0-9]{1,19}$
decrypted_avatar_url
string

Group avatar URL (https) to show on the invite preview.

Maximum string length: 2048
Pattern: ^https://
decrypted_title
string

Group name to show on the invite preview.

Maximum string length: 1024
invite_url
string

Invite link built by the client, in the form https://x.com/i/chat/group_join/<conversation_id>/, where the token is exactly 10 letters, digits, '-' or '_'. The conversation segment must match the path ID. It is part of the signed payload, so it is required when action_signatures is sent.

Pattern: ^https://x\.com/i/chat/group_join/g[0-9]{1,19}/[A-Za-z0-9_-]{10}$
validity_duration_msec
string

How long the link stays valid, in milliseconds, from the time of the request. With action_signatures, send validity_expiry_timestamp_msec instead.

Pattern: ^[0-9]{1,19}$
validity_expiry_timestamp_msec
string

When the link expires, in epoch milliseconds. Must be in the future. If validity_duration_msec is also sent, the two must agree within a minute.

Pattern: ^[0-9]{1,19}$
welcome_message
string

Message shown to people who open the link.

Maximum string length: 1024

Response

The request has succeeded.

data
object
errors
object[]