Segmind Docs
WebsiteConsole
  • Segmind Developer Platform
    • Developer Quickstart
    • Key Concepts
    • Support
    • Authentication
    • Pricing and Billing
    • Flux Fine Tuning
      • Flux fine Tuning API
      • Flux Pro fine tuning API
      • Fine tuning GPU options
    • Webhooks
    • Teams
    • Account and Developer Settings
  • API Reference
    • Model Status
    • Rate Limits
    • Account and Billing APIs
    • Premium models
    • Monitoring
    • Logging
    • Random Seed
  • PixelFlow
    • Getting Started
    • PixelFlow Components
    • PixelFlow Operations
    • Templates
    • Workflow to API
  • Model Hub
  • Dedicated Endpoints
    • Getting started
    • Endpoint APIs
Powered by GitBook
On this page
  • Authentication
  • APIs
  • Endpoints
  • API error codes
  • Postman Collection

API Reference

Welcome to the Segmind API Docs! This guide will help you get started with using our REST APIs.

PreviousAccount and Developer SettingsNextModel Status

Last updated 11 months ago

Authentication

Create an API key

The Segmind Serverless API uses API keys for authentication. To create one, login to your account and head to the on the dashboard.

Use the API

You can authenticate by including your Segmind API key in the Request Header and pass it as x-api-key section of the request.

Example cURL request:

curl --location 'https://api.segmind.com/v1/instantid' \
--header 'x-api-key: YOUR-API-KEY' \
--header 'Content-Type: application/json' \
--data '{
    }'

Example Python request:

import requests

api_key = "YOUR-API-KEY"
url = "https://api.segmind.com/v1/face-to-sticker"

# Request payload
data = {
}

response = requests.post(url, json=data, headers={'x-api-key': api_key})
print(response)

APIs

Endpoints

Base URL

POST https://api.segmind.com/...

Version 1 (v1)

Some endpoints that typically complete their requests within 60 seconds are on version 1. For example: https://api.segmind.com/v1/sdxl1.0-newreality-lightning

Version 2 (v2)

We created v2 to serve APIs that typically take longer than 60 seconds to process.

API error codes

Below are a list of error codes to help you

200 - Output Generated
401 - UnauthorizedUser authentication failed
404 - Not FoundThe requested URL does not exist
405 - Method Not AllowedThe requested HTTP method is not allowed
406 - Not AcceptableNot enough credits
500 - Server ErrorServer had some issue with processing

Postman Collection

Use this Postman collection to get started faster.

To integrate an API, visit the model's page and tab. You can see the list of parameters and example code to get started with the API.

API Keys page
click on the "API"