CharacterAI
CtrlK
  • ๐Ÿ‘‹Welcome
  • ๐Ÿง‘โ€๐Ÿ’ปQuick Start
  • ๐Ÿ› ๏ธAPI
    • ๐Ÿ”‘ Values
    • โš ๏ธ Errors
    • connect
    • ping
    • user
      • info
      • get_profile
      • followers
      • following
      • recent
      • update
    • post
      • get_post
      • my_posts
      • get_posts
      • upvote
      • undo_upvote
      • send_comment
      • delete_comment
      • create
      • delete
      • get_topics
      • feed
    • character
      • create
      • update
      • trending
      • recommended
      • categories
      • info
      • search
      • voices
    • chat
      • create_room
      • rate
      • next_message
      • get_histories
      • get_history
      • get_chat
      • send_message
      • delete_message
      • new_chat
    • chat2
      • next_message
      • send_message
      • get_histories
      • new_chat
      • get_chat
      • get_history
      • rate
      • delete_message
  • ๐Ÿ“šExamples
    • Chatting
    • Parse Chat
  • โš ๏ธIssues
Powered by GitBook
On this page
  1. ๐Ÿ› ๏ธAPI

connect

Connecting to websockets for chat2

async with client.connect('TOKEN') as chat2:
    # Your code

token [str] (optional)

You must specify this parameter if you did not specify a token at the beginning, or just want to use another token

Previousโš ๏ธ ErrorsNextping

Last updated 1 year ago