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

# Auth

> Upon opening a connection to the server, the connecting client should immediately send 
a message to the `auth` channel with the user's login information in the form of the
auhorization token. After doing this, the connection is "bound" to this user and will
receive all information relevant for this user (and that the client is subscribed to).




## AsyncAPI

````yaml asyncapi-reference/asyncapi.yml auth
id: auth
title: Auth
description: >
  Upon opening a connection to the server, the connecting client should
  immediately send 

  a message to the `auth` channel with the user's login information in the form
  of the

  auhorization token. After doing this, the connection is "bound" to this user
  and will

  receive all information relevant for this user (and that the client is
  subscribed to).
servers:
  - id: production-ws
    protocol: wss
    host: api.ctechnology.io
    bindings: []
    variables: []
  - id: playground-ws
    protocol: wss
    host: api.playground.ctechnology.io
    bindings: []
    variables: []
address: auth
parameters: []
bindings: []
operations:
  - &ref_0
    id: publishAuth
    title: Publish auth
    description: Send authentication information
    type: send
    messages:
      - &ref_1
        id: RegisterClient
        contentType: application/json
        payload:
          - name: RegisterClient
            type: object
            properties:
              - name: authorization
                type: string
                description: >
                  The token a user received after logging in. It should be sent
                  in the following 

                  form: `Token XYZ` (similar to the REST API).
                required: false
        headers: []
        jsonPayloadSchema:
          type: object
          title: Authorization
          properties:
            authorization:
              type: string
              pattern: Token [a-z0-9]{64}
              description: >
                The token a user received after logging in. It should be sent in
                the following 

                form: `Token XYZ` (similar to the REST API).
              x-parser-schema-id: <anonymous-schema-1>
          x-parser-schema-id: Authorization
        title: Register client
        example: |-
          {
            "authorization": "Token XYZ"
          }
        bindings: []
        extensions:
          - id: x-parser-unique-object-id
            value: RegisterClient
          - id: x-parser-message-name
            value: RegisterClient
    bindings: []
    extensions:
      - id: x-parser-unique-object-id
        value: auth
sendOperations: []
receiveOperations:
  - *ref_0
sendMessages: []
receiveMessages:
  - *ref_1
extensions:
  - id: x-parser-unique-object-id
    value: auth
securitySchemes: []

````