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

> ## Agent Instructions
> Use Stable documentation by default. Honor an explicit Beta request or a URL under /docs/beta/. If the requested version conflicts with the installed CLI package or API origin, clarify the target before writing integration code.
> Pages under /docs/beta/ document Beta; other product pages document Stable. Keep the CLI package, commands, API origin, and credentials within the selected version. State the documentation version in your answer.
> For MCP search, always pass version: Stable or version: Beta. Unfiltered search mixes both versions. For filesystem reads, keep Beta queries under /beta/ and exclude /beta/ from Stable queries; discover paths before reading them.
> The public docs base is https://photon.codes/docs. Convert MCP page paths to public URLs under that base, preserving /beta/ when present. Read https://photon.codes/docs/skill.md for version selection and https://photon.codes/docs/llms.txt for the version indexes.

# Get SMS line campaign assignment

> Read the last confirmed campaign and current eligibility. Follow changes through their operations. Eligibility is a control-plane assessment, not a delivery or recipient-consent guarantee.



## OpenAPI

````yaml https://api.photon.codes/openapi.json get /v1/projects/{id}/platforms/sms/lines/{resourceId}/campaign
openapi: 3.1.0
info:
  title: Photon API
  version: 1.0.0
servers:
  - url: https://api.photon.codes
security: []
paths:
  /v1/projects/{id}/platforms/sms/lines/{resourceId}/campaign:
    get:
      tags:
        - SMS campaigns
      summary: Get SMS line campaign assignment
      description: >-
        Read the last confirmed campaign and current eligibility. Follow changes
        through their operations. Eligibility is a control-plane assessment, not
        a delivery or recipient-consent guarantee.
      operationId: getSmsLineCampaignAssignment
      parameters:
        - in: path
          name: id
          required: true
          schema:
            type: string
        - in: path
          name: resourceId
          required: true
          schema:
            type: string
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetSmsLineCampaignAssignmentResponse'
          description: Current assignment, including an untouched version of 1.
          headers:
            Cache-Control:
              description: Assignment and operation responses must not be cached.
              schema:
                example: no-store
                type: string
            Deprecation:
              $ref: '#/components/headers/Deprecation'
            Idempotent-Replayed:
              $ref: '#/components/headers/Idempotent-Replayed'
            Link:
              $ref: '#/components/headers/Link'
            RateLimit:
              $ref: '#/components/headers/RateLimit'
            RateLimit-Policy:
              $ref: '#/components/headers/RateLimit-Policy'
            Retry-After:
              $ref: '#/components/headers/Retry-After'
            Sunset:
              $ref: '#/components/headers/Sunset'
            X-Request-ID:
              $ref: '#/components/headers/X-Request-ID'
            X-Trace-ID:
              $ref: '#/components/headers/X-Trace-ID'
        '400':
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/SmsCampaignInvalidRequestProblem'
          description: 'SMS_CAMPAIGN_INVALID_REQUEST: Invalid SMS campaign request'
          headers:
            Deprecation:
              $ref: '#/components/headers/Deprecation'
            Idempotent-Replayed:
              $ref: '#/components/headers/Idempotent-Replayed'
            Link:
              $ref: '#/components/headers/Link'
            RateLimit:
              $ref: '#/components/headers/RateLimit'
            RateLimit-Policy:
              $ref: '#/components/headers/RateLimit-Policy'
            Retry-After:
              $ref: '#/components/headers/Retry-After'
            Sunset:
              $ref: '#/components/headers/Sunset'
            X-Request-ID:
              $ref: '#/components/headers/X-Request-ID'
            X-Trace-ID:
              $ref: '#/components/headers/X-Trace-ID'
        '401':
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/NotAuthenticatedProblem'
          description: 'NOT_AUTHENTICATED: Not Authenticated'
          headers:
            Link:
              description: Optional related resources.
              schema:
                type: string
            RateLimit:
              description: Optional rate limit information.
              schema:
                type: string
            RateLimit-Policy:
              description: Optional rate limit policy.
              schema:
                type: string
            Retry-After:
              description: Optional retry delay or HTTP date.
              schema:
                type: string
            WWW-Authenticate:
              required: true
              schema:
                type: string
            X-Request-ID:
              description: Application request identifier.
              schema:
                type: string
        '403':
          content:
            application/problem+json:
              schema:
                $ref: >-
                  #/components/schemas/GetSmsLineCampaignAssignmentForbiddenProblem
          description: >-
            FORBIDDEN: Forbidden; RESOURCE_MISMATCH: Resource Mismatch;
            SMS_CAMPAIGN_ORGANIZATION_MISMATCH: Campaign belongs to another
            organization


            FORBIDDEN: Forbidden; INSUFFICIENT_SCOPE: Insufficient Scope;
            ORGANIZATION_SSO_REQUIRED: Organization SSO Required
          headers:
            Deprecation:
              description: >-
                RFC 9745 structured-field Date at which the operation was or
                will be deprecated: `@` followed by Unix seconds, for example
                `@1767225599`.
              schema:
                pattern: ^@-?[0-9]+$
                type: string
            Idempotent-Replayed:
              description: True when this response was replayed from an earlier attempt.
              schema:
                type: boolean
            Link:
              description: |-
                Links related to lifecycle or remediation documentation.

                Optional related resources.
              schema:
                type: string
            RateLimit:
              description: |-
                Current rate-limit state.

                Optional rate limit information.
              schema:
                type: string
            RateLimit-Policy:
              description: |-
                Rate-limit policy applied by the gateway.

                Optional rate limit policy.
              schema:
                type: string
            Retry-After:
              description: |-
                Delay before retrying, in seconds or as an HTTP date.

                Optional retry delay or HTTP date.
              schema:
                type: string
            Sunset:
              description: >-
                RFC 8594 HTTP-date (IMF-fixdate) after which the operation may
                become unavailable, for example `Thu, 31 Dec 2026 23:59:59 GMT`.
              schema:
                pattern: >-
                  ^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), [0-9]{2}
                  (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4}
                  [0-9]{2}:[0-9]{2}:[0-9]{2} GMT$
                type: string
            X-Request-ID:
              description: |-
                Identifier for this HTTP attempt.

                Application request identifier.
              schema:
                type: string
            X-Trace-ID:
              description: >-
                Trace ID of this request. Sent alongside X-Request-ID when a
                middleware published a trace ID for the request.
              schema:
                pattern: ^(?!0{32}$)[0-9a-f]{32}$
                type: string
        '404':
          content:
            application/problem+json:
              schema:
                $ref: >-
                  #/components/schemas/GetSmsLineCampaignAssignmentNotFoundProblem
          description: >-
            SMS_CAMPAIGN_NOT_FOUND: Campaign not found; SMS_LINE_NOT_FOUND: SMS
            line not found
          headers:
            Deprecation:
              $ref: '#/components/headers/Deprecation'
            Idempotent-Replayed:
              $ref: '#/components/headers/Idempotent-Replayed'
            Link:
              $ref: '#/components/headers/Link'
            RateLimit:
              $ref: '#/components/headers/RateLimit'
            RateLimit-Policy:
              $ref: '#/components/headers/RateLimit-Policy'
            Retry-After:
              $ref: '#/components/headers/Retry-After'
            Sunset:
              $ref: '#/components/headers/Sunset'
            X-Request-ID:
              $ref: '#/components/headers/X-Request-ID'
            X-Trace-ID:
              $ref: '#/components/headers/X-Trace-ID'
        '409':
          content:
            application/problem+json:
              schema:
                $ref: >-
                  #/components/schemas/GetSmsLineCampaignAssignmentConflictProblem
          description: >-
            PROJECT_CLOSING: Project Is Closing; SMS_LINE_UNSUPPORTED: SMS line
            unsupported; SMS_CAMPAIGN_NOT_READY: Campaign not ready;
            SMS_CAMPAIGN_VERSION_CONFLICT: Assignment version conflict;
            SMS_CAMPAIGN_CAPACITY_EXCEEDED: Campaign number capacity exhausted;
            SMS_CAMPAIGN_RECONCILIATION_REQUIRED: Campaign reconciliation
            required; SMS_CAMPAIGN_MUTATION_IN_PROGRESS: Assignment mutation in
            progress
          headers:
            Deprecation:
              $ref: '#/components/headers/Deprecation'
            Idempotent-Replayed:
              $ref: '#/components/headers/Idempotent-Replayed'
            Link:
              $ref: '#/components/headers/Link'
            RateLimit:
              $ref: '#/components/headers/RateLimit'
            RateLimit-Policy:
              $ref: '#/components/headers/RateLimit-Policy'
            Retry-After:
              $ref: '#/components/headers/Retry-After'
            Sunset:
              $ref: '#/components/headers/Sunset'
            X-Request-ID:
              $ref: '#/components/headers/X-Request-ID'
            X-Trace-ID:
              $ref: '#/components/headers/X-Trace-ID'
        '429':
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/RateLimitedProblem'
          description: 'RATE_LIMITED: Too Many Requests'
          headers:
            Deprecation:
              $ref: '#/components/headers/Deprecation'
            Idempotent-Replayed:
              $ref: '#/components/headers/Idempotent-Replayed'
            Link:
              $ref: '#/components/headers/Link'
            RateLimit:
              $ref: '#/components/headers/RateLimit'
            RateLimit-Policy:
              $ref: '#/components/headers/RateLimit-Policy'
            Retry-After:
              $ref: '#/components/headers/Retry-After'
            Sunset:
              $ref: '#/components/headers/Sunset'
            X-Request-ID:
              $ref: '#/components/headers/X-Request-ID'
            X-Trace-ID:
              $ref: '#/components/headers/X-Trace-ID'
        '500':
          content:
            application/problem+json:
              schema:
                $ref: >-
                  #/components/schemas/GetSmsLineCampaignAssignmentInternalServerErrorProblem
          description: |-
            INVALID_AUTH_CONTEXT: Invalid Authentication Context

            INTERNAL_ERROR: Internal Server Error
          headers:
            Deprecation:
              description: >-
                RFC 9745 structured-field Date at which the operation was or
                will be deprecated: `@` followed by Unix seconds, for example
                `@1767225599`.
              schema:
                pattern: ^@-?[0-9]+$
                type: string
            Idempotent-Replayed:
              description: True when this response was replayed from an earlier attempt.
              schema:
                type: boolean
            Link:
              description: |-
                Links related to lifecycle or remediation documentation.

                Optional related resources.
              schema:
                type: string
            RateLimit:
              description: |-
                Current rate-limit state.

                Optional rate limit information.
              schema:
                type: string
            RateLimit-Policy:
              description: |-
                Rate-limit policy applied by the gateway.

                Optional rate limit policy.
              schema:
                type: string
            Retry-After:
              description: |-
                Delay before retrying, in seconds or as an HTTP date.

                Optional retry delay or HTTP date.
              schema:
                type: string
            Sunset:
              description: >-
                RFC 8594 HTTP-date (IMF-fixdate) after which the operation may
                become unavailable, for example `Thu, 31 Dec 2026 23:59:59 GMT`.
              schema:
                pattern: >-
                  ^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), [0-9]{2}
                  (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4}
                  [0-9]{2}:[0-9]{2}:[0-9]{2} GMT$
                type: string
            X-Request-ID:
              description: |-
                Identifier for this HTTP attempt.

                Application request identifier.
              schema:
                type: string
            X-Trace-ID:
              description: >-
                Trace ID of this request. Sent alongside X-Request-ID when a
                middleware published a trace ID for the request.
              schema:
                pattern: ^(?!0{32}$)[0-9a-f]{32}$
                type: string
        '502':
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/UpstreamFailureProblem'
          description: 'UPSTREAM_FAILURE: Upstream Service Failure'
          headers:
            Deprecation:
              $ref: '#/components/headers/Deprecation'
            Idempotent-Replayed:
              $ref: '#/components/headers/Idempotent-Replayed'
            Link:
              $ref: '#/components/headers/Link'
            RateLimit:
              $ref: '#/components/headers/RateLimit'
            RateLimit-Policy:
              $ref: '#/components/headers/RateLimit-Policy'
            Retry-After:
              $ref: '#/components/headers/Retry-After'
            Sunset:
              $ref: '#/components/headers/Sunset'
            X-Request-ID:
              $ref: '#/components/headers/X-Request-ID'
            X-Trace-ID:
              $ref: '#/components/headers/X-Trace-ID'
        '503':
          content:
            application/problem+json:
              schema:
                $ref: >-
                  #/components/schemas/GetSmsLineCampaignAssignmentServiceUnavailableProblem
          description: >-
            UPSTREAM_UNAVAILABLE: Upstream Service Unavailable;
            SMS_CAMPAIGN_CONTEXT_UNAVAILABLE: Campaign context unavailable


            UPSTREAM_UNAVAILABLE: Upstream Service Unavailable
          headers:
            Deprecation:
              description: >-
                RFC 9745 structured-field Date at which the operation was or
                will be deprecated: `@` followed by Unix seconds, for example
                `@1767225599`.
              schema:
                pattern: ^@-?[0-9]+$
                type: string
            Idempotent-Replayed:
              description: True when this response was replayed from an earlier attempt.
              schema:
                type: boolean
            Link:
              description: |-
                Links related to lifecycle or remediation documentation.

                Optional related resources.
              schema:
                type: string
            RateLimit:
              description: |-
                Current rate-limit state.

                Optional rate limit information.
              schema:
                type: string
            RateLimit-Policy:
              description: |-
                Rate-limit policy applied by the gateway.

                Optional rate limit policy.
              schema:
                type: string
            Retry-After:
              description: |-
                Delay before retrying, in seconds or as an HTTP date.

                Optional retry delay or HTTP date.
              schema:
                type: string
            Sunset:
              description: >-
                RFC 8594 HTTP-date (IMF-fixdate) after which the operation may
                become unavailable, for example `Thu, 31 Dec 2026 23:59:59 GMT`.
              schema:
                pattern: >-
                  ^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), [0-9]{2}
                  (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4}
                  [0-9]{2}:[0-9]{2}:[0-9]{2} GMT$
                type: string
            X-Request-ID:
              description: |-
                Identifier for this HTTP attempt.

                Application request identifier.
              schema:
                type: string
            X-Trace-ID:
              description: >-
                Trace ID of this request. Sent alongside X-Request-ID when a
                middleware published a trace ID for the request.
              schema:
                pattern: ^(?!0{32}$)[0-9a-f]{32}$
                type: string
        '504':
          content:
            application/problem+json:
              schema:
                $ref: >-
                  #/components/schemas/GetSmsLineCampaignAssignmentGatewayTimeoutProblem
          description: >-
            REQUEST_TIMEOUT: Request Timeout; UPSTREAM_TIMEOUT: Upstream Service
            Timeout
          headers:
            Deprecation:
              $ref: '#/components/headers/Deprecation'
            Idempotent-Replayed:
              $ref: '#/components/headers/Idempotent-Replayed'
            Link:
              $ref: '#/components/headers/Link'
            RateLimit:
              $ref: '#/components/headers/RateLimit'
            RateLimit-Policy:
              $ref: '#/components/headers/RateLimit-Policy'
            Retry-After:
              $ref: '#/components/headers/Retry-After'
            Sunset:
              $ref: '#/components/headers/Sunset'
            X-Request-ID:
              $ref: '#/components/headers/X-Request-ID'
            X-Trace-ID:
              $ref: '#/components/headers/X-Trace-ID'
      security:
        - accountServiceKey: []
        - projectApiKey: []
components:
  schemas:
    GetSmsLineCampaignAssignmentResponse:
      additionalProperties: {}
      properties:
        campaign:
          anyOf:
            - $ref: '#/components/schemas/SmsLineCampaign'
            - type: 'null'
        eligibility:
          $ref: '#/components/schemas/SmsLineCampaignEligibility'
        reasonCode:
          anyOf:
            - type: string
            - type: 'null'
        resourceId:
          type: string
        version:
          exclusiveMinimum: 0
          maximum: 9007199254740991
          type: integer
      required:
        - campaign
        - eligibility
        - reasonCode
        - resourceId
        - version
      type: object
    SmsCampaignInvalidRequestProblem:
      additionalProperties:
        $ref: '#/components/schemas/JsonValue'
      example:
        code: SMS_CAMPAIGN_INVALID_REQUEST
        status: 400
        title: Invalid SMS campaign request
        type: https://photon.codes/docs/problems/sms-campaign-invalid-request
      properties:
        code:
          const: SMS_CAMPAIGN_INVALID_REQUEST
          type: string
        detail:
          minLength: 1
          type: string
        instance:
          minLength: 1
          type: string
        remediation:
          not: {}
        requestId:
          minLength: 1
          type: string
        status:
          const: 400
          type: number
        title:
          const: Invalid SMS campaign request
          type: string
        type:
          const: https://photon.codes/docs/problems/sms-campaign-invalid-request
          type: string
      required:
        - code
        - status
        - title
        - type
      type: object
    NotAuthenticatedProblem:
      additionalProperties:
        $ref: '#/components/schemas/JsonValue'
      example:
        code: NOT_AUTHENTICATED
        status: 401
        title: Not Authenticated
        type: https://photon.codes/docs/problems/not-authenticated
      properties:
        code:
          const: NOT_AUTHENTICATED
          type: string
        detail:
          minLength: 1
          type: string
        instance:
          minLength: 1
          type: string
        remediation:
          not: {}
        requestId:
          minLength: 1
          type: string
        status:
          const: 401
          type: number
        title:
          const: Not Authenticated
          type: string
        type:
          const: https://photon.codes/docs/problems/not-authenticated
          type: string
      required:
        - code
        - status
        - title
        - type
      type: object
    GetSmsLineCampaignAssignmentForbiddenProblem:
      oneOf:
        - $ref: '#/components/schemas/ForbiddenProblem'
        - $ref: '#/components/schemas/InsufficientScopeProblem'
        - $ref: '#/components/schemas/OrganizationSsoRequiredProblem'
        - $ref: '#/components/schemas/ResourceMismatchProblem'
        - $ref: '#/components/schemas/SmsCampaignOrganizationMismatchProblem'
    GetSmsLineCampaignAssignmentNotFoundProblem:
      oneOf:
        - $ref: '#/components/schemas/SmsCampaignNotFoundProblem'
        - $ref: '#/components/schemas/SmsLineNotFoundProblem'
    GetSmsLineCampaignAssignmentConflictProblem:
      oneOf:
        - $ref: '#/components/schemas/ProjectClosingProblem'
        - $ref: '#/components/schemas/SmsLineUnsupportedProblem'
        - $ref: '#/components/schemas/SmsCampaignNotReadyProblem'
        - $ref: '#/components/schemas/SmsCampaignVersionConflictProblem'
        - $ref: '#/components/schemas/SmsCampaignCapacityExceededProblem'
        - $ref: '#/components/schemas/SmsCampaignReconciliationRequiredProblem'
        - $ref: '#/components/schemas/SmsCampaignMutationInProgressProblem'
    RateLimitedProblem:
      additionalProperties:
        $ref: '#/components/schemas/JsonValue'
      example:
        code: RATE_LIMITED
        status: 429
        title: Too Many Requests
        type: https://photon.codes/docs/problems/rate-limited
      properties:
        code:
          const: RATE_LIMITED
          type: string
        detail:
          minLength: 1
          type: string
        instance:
          minLength: 1
          type: string
        remediation:
          not: {}
        requestId:
          minLength: 1
          type: string
        status:
          const: 429
          type: number
        title:
          const: Too Many Requests
          type: string
        type:
          const: https://photon.codes/docs/problems/rate-limited
          type: string
      required:
        - code
        - status
        - title
        - type
      type: object
    GetSmsLineCampaignAssignmentInternalServerErrorProblem:
      oneOf:
        - $ref: '#/components/schemas/InternalErrorProblem'
        - $ref: '#/components/schemas/InvalidAuthContextProblem'
    UpstreamFailureProblem:
      additionalProperties:
        $ref: '#/components/schemas/JsonValue'
      example:
        code: UPSTREAM_FAILURE
        status: 502
        title: Upstream Service Failure
        type: https://photon.codes/docs/problems/upstream-failure
      properties:
        code:
          const: UPSTREAM_FAILURE
          type: string
        detail:
          minLength: 1
          type: string
        instance:
          minLength: 1
          type: string
        remediation:
          not: {}
        requestId:
          minLength: 1
          type: string
        status:
          const: 502
          type: number
        title:
          const: Upstream Service Failure
          type: string
        type:
          const: https://photon.codes/docs/problems/upstream-failure
          type: string
      required:
        - code
        - status
        - title
        - type
      type: object
    GetSmsLineCampaignAssignmentServiceUnavailableProblem:
      oneOf:
        - $ref: '#/components/schemas/SmsCampaignContextUnavailableProblem'
        - $ref: '#/components/schemas/UpstreamUnavailableProblem'
    GetSmsLineCampaignAssignmentGatewayTimeoutProblem:
      oneOf:
        - $ref: '#/components/schemas/RequestTimeoutProblem'
        - $ref: '#/components/schemas/UpstreamTimeoutProblem'
    SmsLineCampaign:
      additionalProperties: {}
      properties:
        id:
          type: string
        organizationId:
          type: string
      required:
        - id
        - organizationId
      type: object
    SmsLineCampaignEligibility:
      enum:
        - eligible
        - blocked
        - unknown
      type: string
    JsonValue:
      anyOf:
        - type: string
        - type: number
        - type: boolean
        - type: 'null'
        - items:
            $ref: '#/components/schemas/JsonValue'
          type: array
        - additionalProperties:
            $ref: '#/components/schemas/JsonValue'
          propertyNames:
            type: string
          type: object
    ForbiddenProblem:
      additionalProperties:
        $ref: '#/components/schemas/JsonValue'
      example:
        code: FORBIDDEN
        status: 403
        title: Forbidden
        type: https://photon.codes/docs/problems/forbidden
      properties:
        code:
          const: FORBIDDEN
          type: string
        detail:
          minLength: 1
          type: string
        instance:
          minLength: 1
          type: string
        remediation:
          not: {}
        requestId:
          minLength: 1
          type: string
        status:
          const: 403
          type: number
        title:
          const: Forbidden
          type: string
        type:
          const: https://photon.codes/docs/problems/forbidden
          type: string
      required:
        - code
        - status
        - title
        - type
      type: object
    InsufficientScopeProblem:
      additionalProperties:
        $ref: '#/components/schemas/JsonValue'
      example:
        code: INSUFFICIENT_SCOPE
        status: 403
        title: Insufficient Scope
        type: https://photon.codes/docs/problems/insufficient-scope
      properties:
        code:
          const: INSUFFICIENT_SCOPE
          type: string
        detail:
          minLength: 1
          type: string
        instance:
          minLength: 1
          type: string
        remediation:
          not: {}
        requestId:
          minLength: 1
          type: string
        status:
          const: 403
          type: number
        title:
          const: Insufficient Scope
          type: string
        type:
          const: https://photon.codes/docs/problems/insufficient-scope
          type: string
      required:
        - code
        - status
        - title
        - type
      type: object
    OrganizationSsoRequiredProblem:
      additionalProperties:
        $ref: '#/components/schemas/JsonValue'
      example:
        code: ORGANIZATION_SSO_REQUIRED
        status: 403
        title: Organization SSO Required
        type: https://photon.codes/docs/problems/organization-sso-required
      properties:
        code:
          const: ORGANIZATION_SSO_REQUIRED
          type: string
        detail:
          minLength: 1
          type: string
        instance:
          minLength: 1
          type: string
        remediation:
          not: {}
        requestId:
          minLength: 1
          type: string
        status:
          const: 403
          type: number
        title:
          const: Organization SSO Required
          type: string
        type:
          const: https://photon.codes/docs/problems/organization-sso-required
          type: string
      required:
        - code
        - status
        - title
        - type
      type: object
    ResourceMismatchProblem:
      additionalProperties:
        $ref: '#/components/schemas/JsonValue'
      example:
        code: RESOURCE_MISMATCH
        status: 403
        title: Resource Mismatch
        type: https://photon.codes/docs/problems/resource-mismatch
      properties:
        code:
          const: RESOURCE_MISMATCH
          type: string
        detail:
          minLength: 1
          type: string
        instance:
          minLength: 1
          type: string
        remediation:
          not: {}
        requestId:
          minLength: 1
          type: string
        status:
          const: 403
          type: number
        title:
          const: Resource Mismatch
          type: string
        type:
          const: https://photon.codes/docs/problems/resource-mismatch
          type: string
      required:
        - code
        - status
        - title
        - type
      type: object
    SmsCampaignOrganizationMismatchProblem:
      additionalProperties:
        $ref: '#/components/schemas/JsonValue'
      example:
        code: SMS_CAMPAIGN_ORGANIZATION_MISMATCH
        status: 403
        title: Campaign belongs to another organization
        type: https://photon.codes/docs/problems/sms-campaign-organization-mismatch
      properties:
        code:
          const: SMS_CAMPAIGN_ORGANIZATION_MISMATCH
          type: string
        detail:
          minLength: 1
          type: string
        instance:
          minLength: 1
          type: string
        remediation:
          not: {}
        requestId:
          minLength: 1
          type: string
        status:
          const: 403
          type: number
        title:
          const: Campaign belongs to another organization
          type: string
        type:
          const: >-
            https://photon.codes/docs/problems/sms-campaign-organization-mismatch
          type: string
      required:
        - code
        - status
        - title
        - type
      type: object
    SmsCampaignNotFoundProblem:
      additionalProperties:
        $ref: '#/components/schemas/JsonValue'
      example:
        code: SMS_CAMPAIGN_NOT_FOUND
        status: 404
        title: Campaign not found
        type: https://photon.codes/docs/problems/sms-campaign-not-found
      properties:
        code:
          const: SMS_CAMPAIGN_NOT_FOUND
          type: string
        detail:
          minLength: 1
          type: string
        instance:
          minLength: 1
          type: string
        remediation:
          not: {}
        requestId:
          minLength: 1
          type: string
        status:
          const: 404
          type: number
        title:
          const: Campaign not found
          type: string
        type:
          const: https://photon.codes/docs/problems/sms-campaign-not-found
          type: string
      required:
        - code
        - status
        - title
        - type
      type: object
    SmsLineNotFoundProblem:
      additionalProperties:
        $ref: '#/components/schemas/JsonValue'
      example:
        code: SMS_LINE_NOT_FOUND
        status: 404
        title: SMS line not found
        type: https://photon.codes/docs/problems/sms-line-not-found
      properties:
        code:
          const: SMS_LINE_NOT_FOUND
          type: string
        detail:
          minLength: 1
          type: string
        instance:
          minLength: 1
          type: string
        remediation:
          not: {}
        requestId:
          minLength: 1
          type: string
        status:
          const: 404
          type: number
        title:
          const: SMS line not found
          type: string
        type:
          const: https://photon.codes/docs/problems/sms-line-not-found
          type: string
      required:
        - code
        - status
        - title
        - type
      type: object
    ProjectClosingProblem:
      additionalProperties:
        $ref: '#/components/schemas/JsonValue'
      example:
        code: PROJECT_CLOSING
        status: 409
        title: Project Is Closing
        type: https://photon.codes/docs/problems/project-closing
      properties:
        code:
          const: PROJECT_CLOSING
          type: string
        detail:
          minLength: 1
          type: string
        instance:
          minLength: 1
          type: string
        remediation:
          not: {}
        requestId:
          minLength: 1
          type: string
        status:
          const: 409
          type: number
        title:
          const: Project Is Closing
          type: string
        type:
          const: https://photon.codes/docs/problems/project-closing
          type: string
      required:
        - code
        - status
        - title
        - type
      type: object
    SmsLineUnsupportedProblem:
      additionalProperties:
        $ref: '#/components/schemas/JsonValue'
      example:
        code: SMS_LINE_UNSUPPORTED
        status: 409
        title: SMS line unsupported
        type: https://photon.codes/docs/problems/sms-line-unsupported
      properties:
        code:
          const: SMS_LINE_UNSUPPORTED
          type: string
        detail:
          minLength: 1
          type: string
        instance:
          minLength: 1
          type: string
        remediation:
          not: {}
        requestId:
          minLength: 1
          type: string
        status:
          const: 409
          type: number
        title:
          const: SMS line unsupported
          type: string
        type:
          const: https://photon.codes/docs/problems/sms-line-unsupported
          type: string
      required:
        - code
        - status
        - title
        - type
      type: object
    SmsCampaignNotReadyProblem:
      additionalProperties:
        $ref: '#/components/schemas/JsonValue'
      example:
        code: SMS_CAMPAIGN_NOT_READY
        status: 409
        title: Campaign not ready
        type: https://photon.codes/docs/problems/sms-campaign-not-ready
      properties:
        code:
          const: SMS_CAMPAIGN_NOT_READY
          type: string
        detail:
          minLength: 1
          type: string
        instance:
          minLength: 1
          type: string
        remediation:
          not: {}
        requestId:
          minLength: 1
          type: string
        status:
          const: 409
          type: number
        title:
          const: Campaign not ready
          type: string
        type:
          const: https://photon.codes/docs/problems/sms-campaign-not-ready
          type: string
      required:
        - code
        - status
        - title
        - type
      type: object
    SmsCampaignVersionConflictProblem:
      additionalProperties:
        $ref: '#/components/schemas/JsonValue'
      example:
        code: SMS_CAMPAIGN_VERSION_CONFLICT
        status: 409
        title: Assignment version conflict
        type: https://photon.codes/docs/problems/sms-campaign-version-conflict
      properties:
        code:
          const: SMS_CAMPAIGN_VERSION_CONFLICT
          type: string
        detail:
          minLength: 1
          type: string
        instance:
          minLength: 1
          type: string
        remediation:
          not: {}
        requestId:
          minLength: 1
          type: string
        status:
          const: 409
          type: number
        title:
          const: Assignment version conflict
          type: string
        type:
          const: https://photon.codes/docs/problems/sms-campaign-version-conflict
          type: string
      required:
        - code
        - status
        - title
        - type
      type: object
    SmsCampaignCapacityExceededProblem:
      additionalProperties:
        $ref: '#/components/schemas/JsonValue'
      example:
        code: SMS_CAMPAIGN_CAPACITY_EXCEEDED
        status: 409
        title: Campaign number capacity exhausted
        type: https://photon.codes/docs/problems/sms-campaign-capacity-exceeded
      properties:
        code:
          const: SMS_CAMPAIGN_CAPACITY_EXCEEDED
          type: string
        detail:
          minLength: 1
          type: string
        instance:
          minLength: 1
          type: string
        remediation:
          not: {}
        requestId:
          minLength: 1
          type: string
        status:
          const: 409
          type: number
        title:
          const: Campaign number capacity exhausted
          type: string
        type:
          const: https://photon.codes/docs/problems/sms-campaign-capacity-exceeded
          type: string
      required:
        - code
        - status
        - title
        - type
      type: object
    SmsCampaignReconciliationRequiredProblem:
      additionalProperties:
        $ref: '#/components/schemas/JsonValue'
      example:
        code: SMS_CAMPAIGN_RECONCILIATION_REQUIRED
        status: 409
        title: Campaign reconciliation required
        type: >-
          https://photon.codes/docs/problems/sms-campaign-reconciliation-required
      properties:
        code:
          const: SMS_CAMPAIGN_RECONCILIATION_REQUIRED
          type: string
        detail:
          minLength: 1
          type: string
        instance:
          minLength: 1
          type: string
        remediation:
          not: {}
        requestId:
          minLength: 1
          type: string
        status:
          const: 409
          type: number
        title:
          const: Campaign reconciliation required
          type: string
        type:
          const: >-
            https://photon.codes/docs/problems/sms-campaign-reconciliation-required
          type: string
      required:
        - code
        - status
        - title
        - type
      type: object
    SmsCampaignMutationInProgressProblem:
      additionalProperties:
        $ref: '#/components/schemas/JsonValue'
      properties:
        code:
          const: SMS_CAMPAIGN_MUTATION_IN_PROGRESS
          type: string
        detail:
          minLength: 1
          type: string
        instance:
          minLength: 1
          type: string
        operationId:
          type: string
        operationUrl:
          minLength: 1
          type: string
        remediation:
          not: {}
        requestId:
          minLength: 1
          type: string
        status:
          const: 409
          type: number
        title:
          const: Assignment mutation in progress
          type: string
        type:
          const: https://photon.codes/docs/problems/sms-campaign-mutation-in-progress
          type: string
      required:
        - operationId
        - operationUrl
        - code
        - status
        - title
        - type
      type: object
    InternalErrorProblem:
      additionalProperties:
        $ref: '#/components/schemas/JsonValue'
      example:
        code: INTERNAL_ERROR
        status: 500
        title: Internal Server Error
        type: https://photon.codes/docs/problems/internal-error
      properties:
        code:
          const: INTERNAL_ERROR
          type: string
        detail:
          minLength: 1
          type: string
        instance:
          minLength: 1
          type: string
        remediation:
          not: {}
        requestId:
          minLength: 1
          type: string
        status:
          const: 500
          type: number
        title:
          const: Internal Server Error
          type: string
        type:
          const: https://photon.codes/docs/problems/internal-error
          type: string
      required:
        - code
        - status
        - title
        - type
      type: object
    InvalidAuthContextProblem:
      additionalProperties:
        $ref: '#/components/schemas/JsonValue'
      example:
        code: INVALID_AUTH_CONTEXT
        status: 500
        title: Invalid Authentication Context
        type: https://photon.codes/docs/problems/invalid-auth-context
      properties:
        code:
          const: INVALID_AUTH_CONTEXT
          type: string
        detail:
          minLength: 1
          type: string
        instance:
          minLength: 1
          type: string
        remediation:
          not: {}
        requestId:
          minLength: 1
          type: string
        status:
          const: 500
          type: number
        title:
          const: Invalid Authentication Context
          type: string
        type:
          const: https://photon.codes/docs/problems/invalid-auth-context
          type: string
      required:
        - code
        - status
        - title
        - type
      type: object
    SmsCampaignContextUnavailableProblem:
      additionalProperties:
        $ref: '#/components/schemas/JsonValue'
      example:
        code: SMS_CAMPAIGN_CONTEXT_UNAVAILABLE
        status: 503
        title: Campaign context unavailable
        type: https://photon.codes/docs/problems/sms-campaign-context-unavailable
      properties:
        code:
          const: SMS_CAMPAIGN_CONTEXT_UNAVAILABLE
          type: string
        detail:
          minLength: 1
          type: string
        instance:
          minLength: 1
          type: string
        remediation:
          not: {}
        requestId:
          minLength: 1
          type: string
        status:
          const: 503
          type: number
        title:
          const: Campaign context unavailable
          type: string
        type:
          const: https://photon.codes/docs/problems/sms-campaign-context-unavailable
          type: string
      required:
        - code
        - status
        - title
        - type
      type: object
    UpstreamUnavailableProblem:
      additionalProperties:
        $ref: '#/components/schemas/JsonValue'
      example:
        code: UPSTREAM_UNAVAILABLE
        status: 503
        title: Upstream Service Unavailable
        type: https://photon.codes/docs/problems/upstream-unavailable
      properties:
        code:
          const: UPSTREAM_UNAVAILABLE
          type: string
        detail:
          minLength: 1
          type: string
        instance:
          minLength: 1
          type: string
        remediation:
          not: {}
        requestId:
          minLength: 1
          type: string
        status:
          const: 503
          type: number
        title:
          const: Upstream Service Unavailable
          type: string
        type:
          const: https://photon.codes/docs/problems/upstream-unavailable
          type: string
      required:
        - code
        - status
        - title
        - type
      type: object
    RequestTimeoutProblem:
      additionalProperties:
        $ref: '#/components/schemas/JsonValue'
      example:
        code: REQUEST_TIMEOUT
        status: 504
        title: Request Timeout
        type: https://photon.codes/docs/problems/request-timeout
      properties:
        code:
          const: REQUEST_TIMEOUT
          type: string
        detail:
          minLength: 1
          type: string
        instance:
          minLength: 1
          type: string
        remediation:
          not: {}
        requestId:
          minLength: 1
          type: string
        status:
          const: 504
          type: number
        title:
          const: Request Timeout
          type: string
        type:
          const: https://photon.codes/docs/problems/request-timeout
          type: string
      required:
        - code
        - status
        - title
        - type
      type: object
    UpstreamTimeoutProblem:
      additionalProperties:
        $ref: '#/components/schemas/JsonValue'
      example:
        code: UPSTREAM_TIMEOUT
        status: 504
        title: Upstream Service Timeout
        type: https://photon.codes/docs/problems/upstream-timeout
      properties:
        code:
          const: UPSTREAM_TIMEOUT
          type: string
        detail:
          minLength: 1
          type: string
        instance:
          minLength: 1
          type: string
        remediation:
          not: {}
        requestId:
          minLength: 1
          type: string
        status:
          const: 504
          type: number
        title:
          const: Upstream Service Timeout
          type: string
        type:
          const: https://photon.codes/docs/problems/upstream-timeout
          type: string
      required:
        - code
        - status
        - title
        - type
      type: object
  headers:
    Deprecation:
      description: >-
        RFC 9745 structured-field Date at which the operation was or will be
        deprecated: `@` followed by Unix seconds, for example `@1767225599`.
      schema:
        pattern: ^@-?[0-9]+$
        type: string
    Idempotent-Replayed:
      description: True when this response was replayed from an earlier attempt.
      schema:
        type: boolean
    Link:
      description: Links related to lifecycle or remediation documentation.
      schema:
        type: string
    RateLimit:
      description: Current rate-limit state.
      schema:
        type: string
    RateLimit-Policy:
      description: Rate-limit policy applied by the gateway.
      schema:
        type: string
    Retry-After:
      description: Delay before retrying, in seconds or as an HTTP date.
      schema:
        type: string
    Sunset:
      description: >-
        RFC 8594 HTTP-date (IMF-fixdate) after which the operation may become
        unavailable, for example `Thu, 31 Dec 2026 23:59:59 GMT`.
      schema:
        pattern: >-
          ^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), [0-9]{2}
          (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4}
          [0-9]{2}:[0-9]{2}:[0-9]{2} GMT$
        type: string
    X-Request-ID:
      description: Identifier for this HTTP attempt.
      schema:
        type: string
    X-Trace-ID:
      description: >-
        Trace ID of this request. Sent alongside X-Request-ID when a middleware
        published a trace ID for the request.
      schema:
        pattern: ^(?!0{32}$)[0-9a-f]{32}$
        type: string
  securitySchemes:
    accountServiceKey:
      description: >-
        Account Service Key, prefixed with `pho_ask_`, sent as `Authorization:
        Bearer <key>`. Acts on behalf of its owning account, subject to the
        permissions and credential restrictions of each operation. Account
        access tokens and OAuth grants also use the Bearer header. In
        organizations that require SSO, Account Service Keys are not accepted
        for managing the organization's SSO settings, deleting the organization,
        or checking whether it can be deleted.
      scheme: bearer
      type: http
    projectApiKey:
      description: >-
        Project API key, `pho_sk_` prefixed, sent as `Authorization: Bearer
        <key>`. Bound to one project, so it is accepted only under
        `/v1/projects/{projectId}` and refused everywhere else.
      scheme: bearer
      type: http

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.