Appearance
Python SDK - Chat API
About 441 wordsAbout 1 min
Comprehensive code examples for the Stream chat python SDK.
Quick Navigation
- Chat (86 methods)
- Common (84 methods)
- Moderation (31 methods)
- Types Reference - interfaces for API requests/responses
Overview
This documentation covers 201 API methods across 3 categories.
Installation
pip install getstreamBasic Setup
from getstream import Stream
# Initialize the client
client = Stream(
api_key="YOUR_API_KEY",
api_secret="YOUR_API_SECRET"
)Categories
Chat
query_campaigns()- Retrieve a list of campaigns based on specific criteria, helping you manage and analyze multiple marketing efforts simultaneously.get_campaign()- Obtain detailed information about a specific campaign, allowing you to review its current status and settings.start_campaign()- Initiate or schedule a campaign to begin at a designated time, enabling you to automate your marketing and outreach activities.stop_campaign()- Stop an ongoing campaign to prevent further messages from being sent, useful when campaign objectives have been achieved or if errors are detected.query_channels()- Access a list of communication channels available in your account, facilitating efficient management and selection for your campaigns.- ... and 81 more methods
Common
get_app()- Retrieve the current application settings to understand or verify the configuration. Use this method when you need to view the existing app settings without making changes.update_app()- Modify the application settings to align with new requirements or preferences. Use this method when you need to update the app configuration.list_block_lists()- Get a list of all existing block lists to review or manage them. Use this method when you need an overview of current block lists.create_block_list()- Create a new block list to restrict certain content or users as per your criteria. Use this method when setting up a new block list for moderation or content control.get_block_list()- Access a specific block list to view its details and contents. Use this method when you need to inspect the entries of a particular block list.- ... and 79 more methods
Moderation
insert_action_log()- Use this method to record a log of moderation actions taken within a chat, which helps in maintaining a history of actions for accountability and future reference.appeal()- Submit a request to challenge a moderation decision if you believe it was incorrect or unfair, helping to ensure accurate content moderation.get_appeal()- Retrieve details of a specific appeal you have submitted, allowing you to track the status and outcome of the appeal process.query_appeals()- Search and list submitted appeals based on specific criteria, enabling you to manage and review multiple appeals efficiently.ban()- Use this method to prohibit a user from accessing your service due to violations, ensuring a safe and respectful environment.- ... and 26 more methods
Generated from Stream OpenAPI specification