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

# Create Payor Inference

We support two different strategies for payor inference: NEAR\_REALTIME and BASE. We recommend using NEAR\_REALTIME
when you want to get a response quickly (in a matter of seconds) and BASE when you want to get a more accurate response (in a matter of minutes).

Currently, we only support NEAR\_REALTIME and submitting with BASE will run with the NEAR\_RELATIME strategy.

As this is an async endpoint, you will have to make a POST request to this endpoint
and then poll the response using the [GET Payor Inference](/api-reference/v1payorinferenceresource/get-payor-inference) endpoint
until `status=COMPLETED` or `status=FAILED`.


## OpenAPI

````yaml post /public/v1/payor_inference/
openapi: 3.0.2
info:
  title: Silna Public API
  version: '1.0'
servers:
  - url: https://app.silnahealth.com/api
security:
  - bearerAuth: []
paths:
  /public/v1/payor_inference/:
    post:
      tags:
        - V1PayorInferenceResource
      summary: Create Payor Inference
      operationId: V1PayorInferenceResource.post
      parameters: []
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/V1PayorInferenceRequestSchema'
        description: ''
      responses:
        '201':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V1PayorInferencePostResponseSchema'
          headers:
            X-RateLimit-Limit:
              schema:
                type: integer
                description: The maximum number of requests allowed in the time window
            X-RateLimit-Remaining:
              schema:
                type: integer
                description: The number of requests remaining in the current time window
            X-RateLimit-Reset:
              schema:
                type: integer
                description: The time when the rate limit will reset, in Unix timestamp
            Retry-After:
              schema:
                type: number
                description: The number of seconds to wait before making another request
        '400':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ValidationError'
          headers:
            X-RateLimit-Limit:
              schema:
                type: integer
                description: The maximum number of requests allowed in the time window
            X-RateLimit-Remaining:
              schema:
                type: integer
                description: The number of requests remaining in the current time window
            X-RateLimit-Reset:
              schema:
                type: integer
                description: The time when the rate limit will reset, in Unix timestamp
            Retry-After:
              schema:
                type: number
                description: The number of seconds to wait before making another request
        '401':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AuthenticationError'
          headers:
            X-RateLimit-Limit:
              schema:
                type: integer
                description: The maximum number of requests allowed in the time window
            X-RateLimit-Remaining:
              schema:
                type: integer
                description: The number of requests remaining in the current time window
            X-RateLimit-Reset:
              schema:
                type: integer
                description: The time when the rate limit will reset, in Unix timestamp
            Retry-After:
              schema:
                type: number
                description: The number of seconds to wait before making another request
        '404':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ObjectNotFoundError'
          headers:
            X-RateLimit-Limit:
              schema:
                type: integer
                description: The maximum number of requests allowed in the time window
            X-RateLimit-Remaining:
              schema:
                type: integer
                description: The number of requests remaining in the current time window
            X-RateLimit-Reset:
              schema:
                type: integer
                description: The time when the rate limit will reset, in Unix timestamp
            Retry-After:
              schema:
                type: number
                description: The number of seconds to wait before making another request
        '429':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TooManyRequestsError'
          headers:
            X-RateLimit-Limit:
              schema:
                type: integer
                description: The maximum number of requests allowed in the time window
            X-RateLimit-Remaining:
              schema:
                type: integer
                description: The number of requests remaining in the current time window
            X-RateLimit-Reset:
              schema:
                type: integer
                description: The time when the rate limit will reset, in Unix timestamp
            Retry-After:
              schema:
                type: number
                description: The number of seconds to wait before making another request
components:
  schemas:
    V1PayorInferenceRequestSchema:
      properties:
        strategy:
          $ref: '#/components/schemas/PayorInferenceConfigName'
        patient_document_file_ids:
          default: null
          description: Optional list of document file IDs to process
          title: Patient Document File Ids
          nullable: true
          items:
            format: uuid
            type: string
          maxItems: 10
          minItems: 1
          type: array
        text:
          default: null
          description: Payor Text
          title: Text
          nullable: true
          maxLength: 5000
          minLength: 1
          type: string
        patient_id:
          default: null
          description: Optional patient identifier
          title: Patient Id
          nullable: true
          format: uuid
          type: string
        provider_id:
          description: Required provider identifier (for HIPAA compliance)
          format: uuid
          title: Provider Id
          type: string
      required:
        - strategy
        - provider_id
      title: V1PayorInferenceRequestSchema
      type: object
      x-folder: public_api
    V1PayorInferencePostResponseSchema:
      properties:
        id:
          format: uuid
          title: Id
          type: string
      required:
        - id
      title: V1PayorInferencePostResponseSchema
      type: object
      x-folder: public_api
    ValidationError:
      type: object
      required:
        - message
      properties:
        message:
          type: string
          description: Human readable error message
      x-folder: null
    AuthenticationError:
      type: object
      required:
        - message
      properties:
        message:
          type: string
          description: Human readable error message
        type:
          $ref: '#/components/schemas/PublicApiErrorType'
      x-folder: null
    ObjectNotFoundError:
      type: object
      required:
        - message
      properties:
        message:
          type: string
          description: Human readable error message
      x-folder: null
    TooManyRequestsError:
      type: object
      required:
        - message
      properties:
        message:
          type: string
          description: Human readable error message
      x-folder: null
    PayorInferenceConfigName:
      type: string
      enum:
        - NEAR_REALTIME
        - BASE
      x-folder: payor_inference
    PublicApiErrorType:
      type: string
      enum:
        - AUTH_INVALID_REQUEST_HEADER
        - AUTH_INVALID_CREDENTIALS
      x-folder: null
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````