enconnect.discord package#

Subpackages#

Submodules#

enconnect.discord.client module#

Functions and routines associated with Enasis Network Remote Connect.

This file is part of Enasis Network software eco-system. Distribution is permitted, for more information consult the project license file.

class enconnect.discord.client.Client(params: ClientParams, logger: Callable[[...], None] | None = None)[source]#

Bases: object

Establish and maintain connection with the chat service.

Parameters:

params – Parameters used to instantiate the class.

property canceled: bool#

Return the value for the attribute from class instance.

Returns:

Value for the attribute from class instance.

property connected: bool#

Return the value for the attribute from class instance.

Returns:

Value for the attribute from class instance.

get_channel(unique: str) dict[str, Any][source]#

Return the information about the object within Discord.

Parameters:

unique – Unique identifier to locate with Discord.

Returns:

Response from upstream request to the server.

get_guild(unique: str) dict[str, Any][source]#

Return the information about the object within Discord.

Parameters:

unique – Unique identifier to locate with Discord.

Returns:

Response from upstream request to the server.

interact_create(event: ClientEvent, **kwargs: Any) None[source]#

Create the interaction using the raw event from server.

Parameters:
  • event – Raw event received from the network peer.

  • kwargs – Keyword arguments passed for downstream.

interact_update(event: ClientEvent, **kwargs: Any) None[source]#

Update the interaction using the raw event from server.

Parameters:
  • event – Raw event received from the network peer.

  • kwargs – Keyword arguments passed for downstream.

message_create(channel: str, **kwargs: Any) Response[source]#

Create the message using the unique Discord identifier.

Parameters:
  • channel – Unique identifier in the Discord server.

  • kwargs – Keyword arguments passed for downstream.

Returns:

Response from upstream request to the server.

message_delete(channel: str, unique: str) Response[source]#

Delete the message using the unique Discord identifiers.

Parameters:
  • channel – Unique identifier in the Discord server.

  • unique – Unique identifier in the Discord server.

Returns:

Response from upstream request to the server.

message_react(channel: str, unique: str, emoji: str) Response[source]#

React to the message with the provided emoji identifier.

Parameters:
  • channel – Unique identifier in the Discord server.

  • unique – Unique identifier in the Discord server.

  • emoji – Unique identifier in the Discord server.

Returns:

Response from upstream request to the server.

message_update(channel: str, unique: str, **kwargs: Any) Response[source]#

Update the message using the unique Discord identifiers.

Parameters:
  • channel – Unique identifier in the Discord server.

  • unique – Unique identifier in the Discord server.

  • payload – Message payload with the Discord syntax.

  • kwargs – Keyword arguments passed for downstream.

Returns:

Response from upstream request to the server.

property mqueue: Queue[ClientEvent]#

Return the value for the attribute from class instance.

Returns:

Value for the attribute from class instance.

property nickname: tuple[str, str] | None#

Return the value for the attribute from class instance.

Returns:

Value for the attribute from class instance.

operate(*, intents: int = 4609) None[source]#

Operate the client and populate queue with the messages.

Parameters:

intents – Determine what content will be received.

property params: ClientParams#

Return the Pydantic model containing the configuration.

Returns:

Pydantic model containing the configuration.

request(method: Literal['delete', 'get', 'post', 'patch', 'put'], path: str, params: dict[str, Any] | None = None, json: dict[str, Any] | None = None, *, data: dict[str, Any] | None = None, files: dict[str, Any] | None = None, timeout: int | None = None) Response[source]#

Return the response for upstream request to the server.

Parameters:
  • method – Method for operation with the API server.

  • path – Path for the location to upstream endpoint.

  • params – Optional parameters included in request.

  • json – Optional JSON payload included in request.

  • data – Optional dict payload included in request.

  • files – Optional file payload included in request.

  • timeout – Timeout waiting for the server response. This will override the default client instantiated.

Returns:

Response from upstream request to the server.

slash_create(command: dict[str, Any], guild: str | None = None) Response[source]#

Register the specified command using upstream endpoint.

Parameters:
  • command – Parameters for registering the command.

  • guild – Discord guild for registering the command.

Returns:

Response from upstream request to the server.

slash_delete(name: str, guild: str | None = None) None[source]#

Remove specified slash command using upstream endpoint.

Parameters:
  • name – Match of the name of the returned commands.

  • guild – Discord guild where command is registred.

socket_recv() dict[str, Any] | None[source]#

Return the content received from the socket connection.

Returns:

Content received from the socket connection.

socket_send(send: dict[str, Any]) None[source]#

Transmit provided content through the socket connection.

Parameters:

send – Content which will be sent through socket.

stop() None[source]#

Gracefully close the connection with the server socket.

enconnect.discord.models module#

Functions and routines associated with Enasis Network Remote Connect.

This file is part of Enasis Network software eco-system. Distribution is permitted, for more information consult the project license file.

pydantic model enconnect.discord.models.ClientEvent[source]#

Bases: BaseModel

Contains information returned from the upstream server.

Show JSON schema
{
   "title": "ClientEvent",
   "description": "Contains information returned from the upstream server.",
   "type": "object",
   "properties": {
      "type": {
         "anyOf": [
            {
               "minLength": 1,
               "type": "string"
            },
            {
               "type": "null"
            }
         ],
         "default": null,
         "description": "Type of event that occurred",
         "title": "Type"
      },
      "opcode": {
         "description": "Type of operation performed",
         "minimum": 0,
         "title": "Opcode",
         "type": "integer"
      },
      "data": {
         "anyOf": [
            {
               "additionalProperties": true,
               "minProperties": 1,
               "type": "object"
            },
            {
               "type": "null"
            }
         ],
         "default": null,
         "description": "Payload with the event data",
         "title": "Data"
      },
      "seqno": {
         "anyOf": [
            {
               "minimum": 0,
               "type": "integer"
            },
            {
               "type": "null"
            }
         ],
         "default": null,
         "description": "Event number within squence",
         "title": "Seqno"
      },
      "original": {
         "additionalProperties": true,
         "description": "Original received from server",
         "minProperties": 1,
         "title": "Original",
         "type": "object"
      },
      "kind": {
         "default": "event",
         "description": "Dynamic field parsed from event",
         "enum": [
            "event",
            "chanmsg",
            "privmsg"
         ],
         "title": "Kind",
         "type": "string"
      },
      "isme": {
         "default": false,
         "description": "Indicates message is from client",
         "title": "Isme",
         "type": "boolean"
      },
      "hasme": {
         "default": false,
         "description": "Indicates message mentions client",
         "title": "Hasme",
         "type": "boolean"
      },
      "whome": {
         "anyOf": [
            {
               "maxItems": 2,
               "minItems": 1,
               "prefixItems": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "string"
                  }
               ],
               "type": "array"
            },
            {
               "type": "null"
            }
         ],
         "default": null,
         "description": "Current nickname of when received",
         "title": "Whome"
      },
      "author": {
         "anyOf": [
            {
               "maxItems": 2,
               "minItems": 1,
               "prefixItems": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "string"
                  }
               ],
               "type": "array"
            },
            {
               "type": "null"
            }
         ],
         "default": null,
         "description": "Dynamic field parsed from event",
         "title": "Author"
      },
      "recipient": {
         "anyOf": [
            {
               "maxItems": 2,
               "minItems": 1,
               "prefixItems": [
                  {
                     "anyOf": [
                        {
                           "type": "string"
                        },
                        {
                           "type": "null"
                        }
                     ]
                  },
                  {
                     "type": "string"
                  }
               ],
               "type": "array"
            },
            {
               "type": "null"
            }
         ],
         "default": null,
         "description": "Dynamic field parsed from event",
         "title": "Recipient"
      },
      "message": {
         "anyOf": [
            {
               "minLength": 1,
               "type": "string"
            },
            {
               "type": "null"
            }
         ],
         "default": null,
         "description": "Dynamic field parsed from event",
         "title": "Message"
      }
   },
   "required": [
      "opcode",
      "original"
   ]
}

Config:
  • extra: str = ignore

Fields:
field author: Annotated[tuple[str, str] | None, FieldInfo(annotation=NoneType, required=False, default=None, description='Dynamic field parsed from event', metadata=[MinLen(min_length=1)])] = None#

Dynamic field parsed from event

Constraints:
  • min_length = 1

field data: Annotated[dict[str, Any] | None, FieldInfo(annotation=NoneType, required=False, default=None, description='Payload with the event data', metadata=[MinLen(min_length=1)])] = None#

Payload with the event data

Constraints:
  • min_length = 1

field hasme: Annotated[bool, FieldInfo(annotation=NoneType, required=False, default=False, description='Indicates message mentions client')] = False#

Indicates message mentions client

field isme: Annotated[bool, FieldInfo(annotation=NoneType, required=False, default=False, description='Indicates message is from client')] = False#

Indicates message is from client

field kind: Annotated[Literal['event', 'chanmsg', 'privmsg'], FieldInfo(annotation=NoneType, required=False, default='event', description='Dynamic field parsed from event')] = 'event'#

Dynamic field parsed from event

field message: Annotated[str | None, FieldInfo(annotation=NoneType, required=False, default=None, description='Dynamic field parsed from event', metadata=[MinLen(min_length=1)])] = None#

Dynamic field parsed from event

Constraints:
  • min_length = 1

field opcode: Annotated[int, FieldInfo(annotation=NoneType, required=True, description='Type of operation performed', metadata=[Ge(ge=0)])] [Required]#

Type of operation performed

Constraints:
  • ge = 0

field original: Annotated[dict[str, Any], FieldInfo(annotation=NoneType, required=True, description='Original received from server', metadata=[MinLen(min_length=1)])] [Required]#

Original received from server

Constraints:
  • min_length = 1

field recipient: Annotated[tuple[str | None, str] | None, FieldInfo(annotation=NoneType, required=False, default=None, description='Dynamic field parsed from event', metadata=[MinLen(min_length=1)])] = None#

Dynamic field parsed from event

Constraints:
  • min_length = 1

field seqno: Annotated[int | None, FieldInfo(annotation=NoneType, required=False, default=None, description='Event number within squence', metadata=[Ge(ge=0)])] = None#

Event number within squence

Constraints:
  • ge = 0

field type: Annotated[str | None, FieldInfo(annotation=NoneType, required=False, default=None, description='Type of event that occurred', metadata=[MinLen(min_length=1)])] = None#

Type of event that occurred

Constraints:
  • min_length = 1

field whome: Annotated[tuple[str, str] | None, FieldInfo(annotation=NoneType, required=False, default=None, description='Current nickname of when received', metadata=[MinLen(min_length=1)])] = None#

Current nickname of when received

Constraints:
  • min_length = 1

enconnect.discord.params module#

Functions and routines associated with Enasis Network Remote Connect.

This file is part of Enasis Network software eco-system. Distribution is permitted, for more information consult the project license file.

pydantic model enconnect.discord.params.ClientParams[source]#

Bases: BaseModel

Process and validate the class configuration parameters.

Show JSON schema
{
   "title": "ClientParams",
   "description": "Process and validate the class configuration parameters.",
   "type": "object",
   "properties": {
      "appid": {
         "anyOf": [
            {
               "minLength": 1,
               "type": "string"
            },
            {
               "type": "null"
            }
         ],
         "default": null,
         "description": "Optional application identifier",
         "title": "Appid"
      },
      "token": {
         "description": "Parameter for the integration",
         "minLength": 1,
         "title": "Token",
         "type": "string"
      },
      "timeout": {
         "default": 30,
         "description": "Timeout connecting to server",
         "maximum": 300,
         "minimum": 1,
         "title": "Timeout",
         "type": "integer"
      },
      "ssl_verify": {
         "default": true,
         "description": "Verify the ceritifcate valid",
         "title": "Ssl Verify",
         "type": "boolean"
      },
      "ssl_capem": {
         "anyOf": [
            {
               "minLength": 1,
               "type": "string"
            },
            {
               "type": "null"
            }
         ],
         "default": null,
         "description": "Verify the ceritifcate valid",
         "title": "Ssl Capem"
      },
      "queue_size": {
         "default": 10000,
         "description": "Maximum size for queued events",
         "maximum": 1000000,
         "minimum": 1000,
         "title": "Queue Size",
         "type": "integer"
      }
   },
   "additionalProperties": false,
   "required": [
      "token"
   ]
}

Config:
  • extra: str = forbid

Fields:
field appid: Annotated[str | None, FieldInfo(annotation=NoneType, required=False, default=None, description='Optional application identifier', metadata=[MinLen(min_length=1)])] = None#

Optional application identifier

Constraints:
  • min_length = 1

field queue_size: Annotated[int, FieldInfo(annotation=NoneType, required=False, default=10000, description='Maximum size for queued events', metadata=[Ge(ge=1000), Le(le=1000000)])] = 10000#

Maximum size for queued events

Constraints:
  • ge = 1000

  • le = 1000000

field ssl_capem: Annotated[str | None, FieldInfo(annotation=NoneType, required=False, default=None, description='Verify the ceritifcate valid', metadata=[MinLen(min_length=1)])] = None#

Verify the ceritifcate valid

Constraints:
  • min_length = 1

field ssl_verify: Annotated[bool, FieldInfo(annotation=NoneType, required=False, default=True, description='Verify the ceritifcate valid')] = True#

Verify the ceritifcate valid

field timeout: Annotated[int, FieldInfo(annotation=NoneType, required=False, default=30, description='Timeout connecting to server', metadata=[Ge(ge=1), Le(le=300)])] = 30#

Timeout connecting to server

Constraints:
  • ge = 1

  • le = 300

field token: Annotated[str, FieldInfo(annotation=NoneType, required=True, description='Parameter for the integration', metadata=[MinLen(min_length=1)])] [Required]#

Parameter for the integration

Constraints:
  • min_length = 1

Module contents#

Functions and routines associated with Enasis Network Remote Connect.

This file is part of Enasis Network software eco-system. Distribution is permitted, for more information consult the project license file.

class enconnect.discord.Client(params: ClientParams, logger: Callable[[...], None] | None = None)[source]#

Bases: object

Establish and maintain connection with the chat service.

Parameters:

params – Parameters used to instantiate the class.

property canceled: bool#

Return the value for the attribute from class instance.

Returns:

Value for the attribute from class instance.

property connected: bool#

Return the value for the attribute from class instance.

Returns:

Value for the attribute from class instance.

get_channel(unique: str) dict[str, Any][source]#

Return the information about the object within Discord.

Parameters:

unique – Unique identifier to locate with Discord.

Returns:

Response from upstream request to the server.

get_guild(unique: str) dict[str, Any][source]#

Return the information about the object within Discord.

Parameters:

unique – Unique identifier to locate with Discord.

Returns:

Response from upstream request to the server.

interact_create(event: ClientEvent, **kwargs: Any) None[source]#

Create the interaction using the raw event from server.

Parameters:
  • event – Raw event received from the network peer.

  • kwargs – Keyword arguments passed for downstream.

interact_update(event: ClientEvent, **kwargs: Any) None[source]#

Update the interaction using the raw event from server.

Parameters:
  • event – Raw event received from the network peer.

  • kwargs – Keyword arguments passed for downstream.

message_create(channel: str, **kwargs: Any) Response[source]#

Create the message using the unique Discord identifier.

Parameters:
  • channel – Unique identifier in the Discord server.

  • kwargs – Keyword arguments passed for downstream.

Returns:

Response from upstream request to the server.

message_delete(channel: str, unique: str) Response[source]#

Delete the message using the unique Discord identifiers.

Parameters:
  • channel – Unique identifier in the Discord server.

  • unique – Unique identifier in the Discord server.

Returns:

Response from upstream request to the server.

message_react(channel: str, unique: str, emoji: str) Response[source]#

React to the message with the provided emoji identifier.

Parameters:
  • channel – Unique identifier in the Discord server.

  • unique – Unique identifier in the Discord server.

  • emoji – Unique identifier in the Discord server.

Returns:

Response from upstream request to the server.

message_update(channel: str, unique: str, **kwargs: Any) Response[source]#

Update the message using the unique Discord identifiers.

Parameters:
  • channel – Unique identifier in the Discord server.

  • unique – Unique identifier in the Discord server.

  • payload – Message payload with the Discord syntax.

  • kwargs – Keyword arguments passed for downstream.

Returns:

Response from upstream request to the server.

property mqueue: Queue[ClientEvent]#

Return the value for the attribute from class instance.

Returns:

Value for the attribute from class instance.

property nickname: tuple[str, str] | None#

Return the value for the attribute from class instance.

Returns:

Value for the attribute from class instance.

operate(*, intents: int = 4609) None[source]#

Operate the client and populate queue with the messages.

Parameters:

intents – Determine what content will be received.

property params: ClientParams#

Return the Pydantic model containing the configuration.

Returns:

Pydantic model containing the configuration.

request(method: Literal['delete', 'get', 'post', 'patch', 'put'], path: str, params: dict[str, Any] | None = None, json: dict[str, Any] | None = None, *, data: dict[str, Any] | None = None, files: dict[str, Any] | None = None, timeout: int | None = None) Response[source]#

Return the response for upstream request to the server.

Parameters:
  • method – Method for operation with the API server.

  • path – Path for the location to upstream endpoint.

  • params – Optional parameters included in request.

  • json – Optional JSON payload included in request.

  • data – Optional dict payload included in request.

  • files – Optional file payload included in request.

  • timeout – Timeout waiting for the server response. This will override the default client instantiated.

Returns:

Response from upstream request to the server.

slash_create(command: dict[str, Any], guild: str | None = None) Response[source]#

Register the specified command using upstream endpoint.

Parameters:
  • command – Parameters for registering the command.

  • guild – Discord guild for registering the command.

Returns:

Response from upstream request to the server.

slash_delete(name: str, guild: str | None = None) None[source]#

Remove specified slash command using upstream endpoint.

Parameters:
  • name – Match of the name of the returned commands.

  • guild – Discord guild where command is registred.

socket_recv() dict[str, Any] | None[source]#

Return the content received from the socket connection.

Returns:

Content received from the socket connection.

socket_send(send: dict[str, Any]) None[source]#

Transmit provided content through the socket connection.

Parameters:

send – Content which will be sent through socket.

stop() None[source]#

Gracefully close the connection with the server socket.

pydantic model enconnect.discord.ClientEvent[source]#

Bases: BaseModel

Contains information returned from the upstream server.

Show JSON schema
{
   "title": "ClientEvent",
   "description": "Contains information returned from the upstream server.",
   "type": "object",
   "properties": {
      "type": {
         "anyOf": [
            {
               "minLength": 1,
               "type": "string"
            },
            {
               "type": "null"
            }
         ],
         "default": null,
         "description": "Type of event that occurred",
         "title": "Type"
      },
      "opcode": {
         "description": "Type of operation performed",
         "minimum": 0,
         "title": "Opcode",
         "type": "integer"
      },
      "data": {
         "anyOf": [
            {
               "additionalProperties": true,
               "minProperties": 1,
               "type": "object"
            },
            {
               "type": "null"
            }
         ],
         "default": null,
         "description": "Payload with the event data",
         "title": "Data"
      },
      "seqno": {
         "anyOf": [
            {
               "minimum": 0,
               "type": "integer"
            },
            {
               "type": "null"
            }
         ],
         "default": null,
         "description": "Event number within squence",
         "title": "Seqno"
      },
      "original": {
         "additionalProperties": true,
         "description": "Original received from server",
         "minProperties": 1,
         "title": "Original",
         "type": "object"
      },
      "kind": {
         "default": "event",
         "description": "Dynamic field parsed from event",
         "enum": [
            "event",
            "chanmsg",
            "privmsg"
         ],
         "title": "Kind",
         "type": "string"
      },
      "isme": {
         "default": false,
         "description": "Indicates message is from client",
         "title": "Isme",
         "type": "boolean"
      },
      "hasme": {
         "default": false,
         "description": "Indicates message mentions client",
         "title": "Hasme",
         "type": "boolean"
      },
      "whome": {
         "anyOf": [
            {
               "maxItems": 2,
               "minItems": 1,
               "prefixItems": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "string"
                  }
               ],
               "type": "array"
            },
            {
               "type": "null"
            }
         ],
         "default": null,
         "description": "Current nickname of when received",
         "title": "Whome"
      },
      "author": {
         "anyOf": [
            {
               "maxItems": 2,
               "minItems": 1,
               "prefixItems": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "string"
                  }
               ],
               "type": "array"
            },
            {
               "type": "null"
            }
         ],
         "default": null,
         "description": "Dynamic field parsed from event",
         "title": "Author"
      },
      "recipient": {
         "anyOf": [
            {
               "maxItems": 2,
               "minItems": 1,
               "prefixItems": [
                  {
                     "anyOf": [
                        {
                           "type": "string"
                        },
                        {
                           "type": "null"
                        }
                     ]
                  },
                  {
                     "type": "string"
                  }
               ],
               "type": "array"
            },
            {
               "type": "null"
            }
         ],
         "default": null,
         "description": "Dynamic field parsed from event",
         "title": "Recipient"
      },
      "message": {
         "anyOf": [
            {
               "minLength": 1,
               "type": "string"
            },
            {
               "type": "null"
            }
         ],
         "default": null,
         "description": "Dynamic field parsed from event",
         "title": "Message"
      }
   },
   "required": [
      "opcode",
      "original"
   ]
}

Config:
  • extra: str = ignore

Fields:
field author: Annotated[tuple[str, str] | None, FieldInfo(annotation=NoneType, required=False, default=None, description='Dynamic field parsed from event', metadata=[MinLen(min_length=1)])] = None#

Dynamic field parsed from event

Constraints:
  • min_length = 1

field data: Annotated[dict[str, Any] | None, FieldInfo(annotation=NoneType, required=False, default=None, description='Payload with the event data', metadata=[MinLen(min_length=1)])] = None#

Payload with the event data

Constraints:
  • min_length = 1

field hasme: Annotated[bool, FieldInfo(annotation=NoneType, required=False, default=False, description='Indicates message mentions client')] = False#

Indicates message mentions client

field isme: Annotated[bool, FieldInfo(annotation=NoneType, required=False, default=False, description='Indicates message is from client')] = False#

Indicates message is from client

field kind: Annotated[Literal['event', 'chanmsg', 'privmsg'], FieldInfo(annotation=NoneType, required=False, default='event', description='Dynamic field parsed from event')] = 'event'#

Dynamic field parsed from event

field message: Annotated[str | None, FieldInfo(annotation=NoneType, required=False, default=None, description='Dynamic field parsed from event', metadata=[MinLen(min_length=1)])] = None#

Dynamic field parsed from event

Constraints:
  • min_length = 1

field opcode: Annotated[int, FieldInfo(annotation=NoneType, required=True, description='Type of operation performed', metadata=[Ge(ge=0)])] [Required]#

Type of operation performed

Constraints:
  • ge = 0

field original: Annotated[dict[str, Any], FieldInfo(annotation=NoneType, required=True, description='Original received from server', metadata=[MinLen(min_length=1)])] [Required]#

Original received from server

Constraints:
  • min_length = 1

field recipient: Annotated[tuple[str | None, str] | None, FieldInfo(annotation=NoneType, required=False, default=None, description='Dynamic field parsed from event', metadata=[MinLen(min_length=1)])] = None#

Dynamic field parsed from event

Constraints:
  • min_length = 1

field seqno: Annotated[int | None, FieldInfo(annotation=NoneType, required=False, default=None, description='Event number within squence', metadata=[Ge(ge=0)])] = None#

Event number within squence

Constraints:
  • ge = 0

field type: Annotated[str | None, FieldInfo(annotation=NoneType, required=False, default=None, description='Type of event that occurred', metadata=[MinLen(min_length=1)])] = None#

Type of event that occurred

Constraints:
  • min_length = 1

field whome: Annotated[tuple[str, str] | None, FieldInfo(annotation=NoneType, required=False, default=None, description='Current nickname of when received', metadata=[MinLen(min_length=1)])] = None#

Current nickname of when received

Constraints:
  • min_length = 1

pydantic model enconnect.discord.ClientParams[source]#

Bases: BaseModel

Process and validate the class configuration parameters.

Show JSON schema
{
   "title": "ClientParams",
   "description": "Process and validate the class configuration parameters.",
   "type": "object",
   "properties": {
      "appid": {
         "anyOf": [
            {
               "minLength": 1,
               "type": "string"
            },
            {
               "type": "null"
            }
         ],
         "default": null,
         "description": "Optional application identifier",
         "title": "Appid"
      },
      "token": {
         "description": "Parameter for the integration",
         "minLength": 1,
         "title": "Token",
         "type": "string"
      },
      "timeout": {
         "default": 30,
         "description": "Timeout connecting to server",
         "maximum": 300,
         "minimum": 1,
         "title": "Timeout",
         "type": "integer"
      },
      "ssl_verify": {
         "default": true,
         "description": "Verify the ceritifcate valid",
         "title": "Ssl Verify",
         "type": "boolean"
      },
      "ssl_capem": {
         "anyOf": [
            {
               "minLength": 1,
               "type": "string"
            },
            {
               "type": "null"
            }
         ],
         "default": null,
         "description": "Verify the ceritifcate valid",
         "title": "Ssl Capem"
      },
      "queue_size": {
         "default": 10000,
         "description": "Maximum size for queued events",
         "maximum": 1000000,
         "minimum": 1000,
         "title": "Queue Size",
         "type": "integer"
      }
   },
   "additionalProperties": false,
   "required": [
      "token"
   ]
}

Config:
  • extra: str = forbid

Fields:
field appid: Annotated[str | None, FieldInfo(annotation=NoneType, required=False, default=None, description='Optional application identifier', metadata=[MinLen(min_length=1)])] = None#

Optional application identifier

Constraints:
  • min_length = 1

field queue_size: Annotated[int, FieldInfo(annotation=NoneType, required=False, default=10000, description='Maximum size for queued events', metadata=[Ge(ge=1000), Le(le=1000000)])] = 10000#

Maximum size for queued events

Constraints:
  • ge = 1000

  • le = 1000000

field ssl_capem: Annotated[str | None, FieldInfo(annotation=NoneType, required=False, default=None, description='Verify the ceritifcate valid', metadata=[MinLen(min_length=1)])] = None#

Verify the ceritifcate valid

Constraints:
  • min_length = 1

field ssl_verify: Annotated[bool, FieldInfo(annotation=NoneType, required=False, default=True, description='Verify the ceritifcate valid')] = True#

Verify the ceritifcate valid

field timeout: Annotated[int, FieldInfo(annotation=NoneType, required=False, default=30, description='Timeout connecting to server', metadata=[Ge(ge=1), Le(le=300)])] = 30#

Timeout connecting to server

Constraints:
  • ge = 1

  • le = 300

field token: Annotated[str, FieldInfo(annotation=NoneType, required=True, description='Parameter for the integration', metadata=[MinLen(min_length=1)])] [Required]#

Parameter for the integration

Constraints:
  • min_length = 1