AI API
WinBay AI API Documentation
Introduction
Welcome to the WinBay API documentation. This guide will help you understand how to interact with our API to leverage over 100 AI models. Whether you're looking to integrate AI capabilities into your applications or automate workflows, our API provides a seamless experience.
Getting Started
To start using WinBay API, follow these simple steps:
Sign Up: Register on our platform to get your API credentials.
API Key: Retrieve your API key from the dashboard.
Make API Requests: Use the API key to authenticate and start making requests to our API endpoints.
Authentication
To authenticate API requests, include your API key in the request headers:
Authorization: Bearer YOUR_API_KEY
Replace YOUR_API_KEY
with your actual API key obtained from the dashboard.
API Reference
Chat Endpoint
URL: https://api.winbay.io/v1/chat/completions
Method: POST
Description: Use this endpoint to interact with our AI models for chat-based applications.
Request Body:
{
"model": "model_name",
"messages": [
{"role": "system", "content": "Your initial prompt here"},
{"role": "user", "content": "Your message here"}
]
}
Parameters:
model
: Specify the AI model you want to use.messages
: An array of message objects, each with arole
("system", "user", or "assistant") andcontent
(the message text).
Example Request:
curl -X POST https://api.winbay.io/v1/chat/completions \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "model_name",
"messages": [
{"role": "system", "content": "You are a helpful assistant."},
{"role": "user", "content": "Hello, how can you help me today?"}
]
}'
Example Use Cases
Here are some examples of how you can use the WinBay API:
Customer Support Chatbot: Automate responses to customer inquiries.
Content Generation: Generate articles, summaries, or creative content.
Data Analysis: Analyze and interpret complex data sets.
Pricing
Our pricing model is pay-as-you-go. You only pay for the resources you consume. For detailed pricing information, visit our Pricing Page.
Support and FAQ
For any questions or issues, please refer to our FAQ section or contact our support team at [email protected].
Last updated