> ## Documentation Index
> Fetch the complete documentation index at: https://docs.avidoai.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Create model pricing

> Creates a new model pricing entry



## OpenAPI

````yaml https://app.stainless.com/api/spec/documented/avido/openapi.documented.yml post /v0/model-pricing
openapi: 3.1.1
info:
  title: Avido API
  description: >-
    Avido's API for LLM usage events, tool calls, trace management, webhook
    validation, and more. See each endpoint's request/response schema for
    details.
  version: 0.1.0
  contact:
    name: Avido Support
    email: support@avidoai.com
    url: https://avidoai.com/support
servers:
  - url: https://api.avidoai.com
    description: Production API
security:
  - ApiKey: []
    ApplicationId: []
paths:
  /v0/model-pricing:
    post:
      tags:
        - Model Pricing
      summary: Create model pricing
      description: Creates a new model pricing entry
      operationId: createModelPricing
      requestBody:
        description: Model pricing data to create
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateModelPricingRequest'
      responses:
        '200':
          description: Successfully created model pricing entry
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ModelPricingResponse'
        '400':
          description: bad request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '401':
          description: unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '403':
          description: forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '422':
          description: invalid input
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ValidationErrorResponse'
        '500':
          description: internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
components:
  schemas:
    CreateModelPricingRequest:
      type: object
      properties:
        modelId:
          type: string
          minLength: 1
          description: Model identifier (e.g., gpt-4o-2024-08-06)
          example: gpt-4o-2024-08-06
        inputCostPer1kTokens:
          type: number
          minimum: 0
          description: Cost per 1,000 input/prompt tokens
          example: 0.0025
        outputCostPer1kTokens:
          type: number
          minimum: 0
          description: Cost per 1,000 output/completion tokens
          example: 0.01
        currency:
          description: Currency code (ISO 4217)
          example: USD
          default: USD
          type: string
      required:
        - modelId
        - inputCostPer1kTokens
        - outputCostPer1kTokens
      title: CreateModelPricingRequest
      description: Request body for creating a model pricing entry
    ModelPricingResponse:
      type: object
      properties:
        data:
          $ref: '#/components/schemas/ModelPricingOutput'
      required:
        - data
      additionalProperties: false
      title: ModelPricingResponse
      description: Successful response containing model pricing data
    ErrorResponse:
      type: object
      properties:
        message:
          type: string
          description: A human-readable error message explaining the error.
          example: Resource not found
      required:
        - message
      additionalProperties: false
      title: ErrorResponse
      description: Standard error format for failed API operations.
    ValidationErrorResponse:
      type: object
      properties:
        message:
          type: string
          description: A human-readable error message indicating what went wrong.
          example: Invalid request data
        issues:
          type: array
          items:
            type: object
            properties:
              code:
                type: string
              message:
                type: string
              path:
                type: array
                items:
                  type: string
            required:
              - code
              - message
              - path
            additionalProperties: false
          description: Array of detailed validation error objects.
          example:
            - code: invalid_string
              message: Invalid UUID
              path:
                - id
      required:
        - message
        - issues
      additionalProperties: false
      title: ValidationErrorResponse
      description: Details about validation errors in incoming requests.
    ModelPricingOutput:
      type: object
      properties:
        id:
          type: string
          format: uuid
          pattern: >-
            ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
          description: Unique identifier
          example: 123e4567-e89b-12d3-a456-426614174000
        orgId:
          type: string
          description: Organization ID
          example: org_123456
        applicationId:
          type: string
          format: uuid
          pattern: >-
            ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
          description: Application ID this model pricing belongs to
          example: 456e4567-e89b-12d3-a456-426614174000
        createdAt:
          description: When created
          example: '2024-01-05T12:34:56.789Z'
          type: string
          format: date-time
          pattern: >-
            ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
        modifiedAt:
          description: When last modified
          example: '2024-01-05T12:34:56.789Z'
          type: string
          format: date-time
          pattern: >-
            ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
        modelId:
          type: string
          description: Model identifier (e.g., gpt-4o-2024-08-06)
          example: gpt-4o-2024-08-06
        inputCostPer1kTokens:
          type: number
          description: Cost per 1,000 input/prompt tokens
          example: 0.0025
        outputCostPer1kTokens:
          type: number
          description: Cost per 1,000 output/completion tokens
          example: 0.01
        currency:
          type: string
          description: Currency code (ISO 4217)
          example: USD
      required:
        - id
        - orgId
        - applicationId
        - createdAt
        - modifiedAt
        - modelId
        - inputCostPer1kTokens
        - outputCostPer1kTokens
        - currency
      additionalProperties: false
      title: ModelPricing
      description: Pricing configuration for an LLM model
  securitySchemes:
    ApiKey:
      type: apiKey
      in: header
      name: x-api-key
      description: Your unique Avido API key
    ApplicationId:
      type: apiKey
      in: header
      name: x-application-id
      description: Your unique Avido Application ID

````