> ## Documentation Index
> Fetch the complete documentation index at: https://docs.threadify.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Joining Threads

> Join threads using invitations or direct access

### Joining

<CodeGroup>
  ```javascript JavaScript theme={null}
  // With invitation token (accessLevel comes from the invite)
  const thread = await connection.join(invitationToken);

  // Direct join (internal services; accessLevel defaults to participant)
  const thread = await connection.join('thread-uuid', 'logistics');
  ```

  ```go Go theme={null}
  // With invitation token (accessLevel comes from the invite)
  thread, err := conn.Join(ctx, threadify.WithJoinToken(invitationToken))
  if err != nil {
      log.Fatal(err)
  }

  // Direct join (internal services; accessLevel defaults to participant)
  thread, err := conn.Join(ctx,
      threadify.WithJoinThreadID("thread-uuid"),
      threadify.WithJoinRole("logistics"),
  )
  if err != nil {
      log.Fatal(err)
  }
  ```

  ```python Python theme={null}
  # With invitation token (accessLevel comes from the invite)
  thread = await connection.join(token=invitation_token)

  # Direct join (internal services; accessLevel defaults to participant)
  thread = await connection.join(
      thread_id="thread-uuid",
      role="logistics",
  )
  ```
</CodeGroup>

### Parameters

| Parameter         | Type   | Description                                                                               |
| ----------------- | ------ | ----------------------------------------------------------------------------------------- |
| `tokenOrThreadId` | string | Invitation token or thread ID                                                             |
| `role`            | string | Business/contract role (required for direct join only, e.g., `"logistics"`, `"supplier"`) |

### Thread Properties

| Property        | Type   | Description        |
| --------------- | ------ | ------------------ |
| `id`            | string | Thread ID          |
| `myRole`        | string | Your assigned role |
| `myAccessLevel` | string | Your access level  |
| `contractName`  | string | Contract name      |
| `status`        | string | Thread status      |

### Next Steps

<CardGroup cols={2}>
  <Card title="Managing Access" icon="users-gear" href="/core-concepts/thread-collaboration/managing-access">
    Manage thread participants and permissions
  </Card>

  <Card title="Data Retrieval" icon="database" href="/core-concepts/data-retrieval/getting-threads">
    Query thread data across participants
  </Card>
</CardGroup>
