Skip to content

Latest commit

 

History

History
156 lines (98 loc) · 5.44 KB

ChatApi.md

File metadata and controls

156 lines (98 loc) · 5.44 KB

\ChatApi

All URIs are relative to https://www.bitmex.com/api/v1

Method HTTP request Description
ChatGet Get /chat Get chat messages.
ChatGetChannels Get /chat/channels Get available channels.
ChatGetConnected Get /chat/connected Get connected users.
ChatGetPinnedMessage Get /chat/pinned Get pinned message for a channel.
ChatNew Post /chat Send a chat message.

ChatGet

[]Chat ChatGet(ctx, optional) Get chat messages.

Required Parameters

Name Type Description Notes
ctx context.Context context for authentication, logging, cancellation, deadlines, tracing, etc.
optional *ChatApiChatGetOpts optional parameters nil if no parameters

Optional Parameters

Optional parameters are passed through a pointer to a ChatApiChatGetOpts struct

Name Type Description Notes
count optional.Int32 Number of results to fetch. [default to 100]
start optional.Int32 Starting ID for results. [default to 0]
reverse optional.Bool If true, will sort results newest first. [default to true]
channelID optional.Float64 Channel id. GET /chat/channels for ids. Global English by default [default to 1]

Return type

[]Chat

Authorization

No authorization required

HTTP request headers

  • Content-Type: application/json, application/x-www-form-urlencoded
  • Accept: application/json, application/xml, text/xml, application/javascript, text/javascript

[Back to top] [Back to API list] [Back to Model list] [Back to README]

ChatGetChannels

[]ChatChannel ChatGetChannels(ctx, ) Get available channels.

Required Parameters

This endpoint does not need any parameter.

Return type

[]ChatChannel

Authorization

No authorization required

HTTP request headers

  • Content-Type: application/json, application/x-www-form-urlencoded
  • Accept: application/json, application/xml, text/xml, application/javascript, text/javascript

[Back to top] [Back to API list] [Back to Model list] [Back to README]

ChatGetConnected

ConnectedUsers ChatGetConnected(ctx, ) Get connected users.

Returns an array with browser users in the first position and API users (bots) in the second position.

Required Parameters

This endpoint does not need any parameter.

Return type

ConnectedUsers

Authorization

No authorization required

HTTP request headers

  • Content-Type: application/json, application/x-www-form-urlencoded
  • Accept: application/json, application/xml, text/xml, application/javascript, text/javascript

[Back to top] [Back to API list] [Back to Model list] [Back to README]

ChatGetPinnedMessage

PinnedMessage ChatGetPinnedMessage(ctx, channelID) Get pinned message for a channel.

Required Parameters

Name Type Description Notes
ctx context.Context context for authentication, logging, cancellation, deadlines, tracing, etc.
channelID float64

Return type

PinnedMessage

Authorization

No authorization required

HTTP request headers

  • Content-Type: application/json, application/x-www-form-urlencoded
  • Accept: application/json, application/xml, text/xml, application/javascript, text/javascript

[Back to top] [Back to API list] [Back to Model list] [Back to README]

ChatNew

Chat ChatNew(ctx, message, optional) Send a chat message.

Required Parameters

Name Type Description Notes
ctx context.Context context for authentication, logging, cancellation, deadlines, tracing, etc.
message string
optional *ChatApiChatNewOpts optional parameters nil if no parameters

Optional Parameters

Optional parameters are passed through a pointer to a ChatApiChatNewOpts struct

Name Type Description Notes

channelID | optional.Float64| Channel to post to. Default 1 (English). | [default to 1]

Return type

Chat

Authorization

apiExpires, apiKey, apiSignature

HTTP request headers

  • Content-Type: application/json, application/x-www-form-urlencoded
  • Accept: application/json, application/xml, text/xml, application/javascript, text/javascript

[Back to top] [Back to API list] [Back to Model list] [Back to README]