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

# Upload reward function



## OpenAPI

````yaml /api-reference/openapi.json post /v1/reward_functions
openapi: 3.1.0
info:
  title: Veri API
  description: >-
    REST API for the Veri RL post-training platform. All requests require a
    Bearer API key (`vk_` prefix).
  license:
    name: ''
  version: 0.1.0
servers:
  - url: https://api.veri.studio
    description: Production
security: []
tags:
  - name: Training jobs
    description: Create, monitor, and manage training jobs.
  - name: Datasets
    description: Upload and connect training datasets.
  - name: Reward functions
    description: Upload and manage reward functions.
  - name: Deployments
    description: Serve trained models and run inference.
  - name: Evaluations
    description: Score models against datasets and benchmarks.
  - name: Volumes
    description: Persistent file storage mounted into jobs.
  - name: Models
    description: Custom model registry deployments serve from.
  - name: Regions
    description: Discover available launch regions.
  - name: GPU
    description: Live GPU availability by provider and region.
  - name: Code artifacts
    description: Upload custom training script bundles.
  - name: Billing
    description: Credit balance and transaction history.
  - name: API keys
    description: Create and revoke API keys.
  - name: Account
    description: The authenticated caller's identity.
  - name: SSH keys
    description: Manage SSH key pairs for compute access.
  - name: Settings
    description: Account-level integrations (Weights & Biases).
paths:
  /v1/reward_functions:
    post:
      tags:
        - Reward functions
      summary: Upload reward function
      operationId: create
      requestBody:
        description: Reward function file upload
        content:
          multipart/form-data: {}
      responses:
        '200':
          description: The created (or existing, on content-hash match) reward function
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RewardFunctionResponse'
        '422':
          description: >-
            File is missing the expected reward function signature, or an
            unknown format
      security:
        - bearerAuth: []
components:
  schemas:
    RewardFunctionResponse:
      type: object
      required:
        - object
        - id
        - name
        - created_at
      properties:
        object:
          type: string
        id:
          type: string
        name:
          type: string
        format:
          $ref: '#/components/schemas/RewardFunctionFormat'
        created_at:
          type: string
          format: date-time
    RewardFunctionFormat:
      type: string
      enum:
        - trl
        - miles
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: API key
      description: API key with the `vk_` prefix. Create one from the dashboard.

````