Skip to main content
This module provides Pydantic models for request and response data structures for the direct messages endpoints of the X API. All models are generated from the OpenAPI specification and provide type safety and validation.

class xdk.direct_messages.models.CreateByConversationIdRequest

Request model for create_by_conversation_id
model_config
ConfigDict
Default: {'populate_by_name': True, 'validate_by_alias': True, 'validate_by_name': True}Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

CreateByConversationIdResponse

Class Bases: BaseModel Response model for create_by_conversation_id

Methods

class xdk.direct_messages.models.CreateByConversationIdResponse

Response model for create_by_conversation_id

class xdk.direct_messages.models.CreateByParticipantIdResponse

Response model for create_by_participant_id

class xdk.direct_messages.models.CreateConversationResponse

Response model for create_conversation

class xdk.direct_messages.models.DeleteEventsResponse

Response model for delete_events

class xdk.direct_messages.models.GetEventsByConversationIdResponse

Response model for get_events_by_conversation_id

class xdk.direct_messages.models.GetEventsByIdResponse

Response model for get_events_by_id

class xdk.direct_messages.models.GetEventsByParticipantIdResponse

Response model for get_events_by_participant_id

class xdk.direct_messages.models.GetEventsResponse

Response model for get_events