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

# Confirm uploaded files

> Pass up to 100 confirmations after their signed PUTs succeed. JSON body limit: 1 MiB. Shared Vault checks permissions and storage, creates or updates artifacts, and schedules indexing. HTTP 200 may contain per-file failures; inspect every result. Native upload tokens expire after one hour. Completion is not idempotent: replay can create another version and repeat indexing. Inspect the destination after an uncertain result before retrying. Does not create filing items or wait for indexing.



## OpenAPI

````yaml /openapi.json post /files/uploads/complete
openapi: 3.0.3
info:
  title: Effective API
  version: 2.0.0
  description: The public Effective REST API. Authenticate using an Effective API key.
servers:
  - url: https://effectiveai.app/api/v2
    description: Production
security:
  - bearerAuth: []
paths:
  /files/uploads/complete:
    post:
      tags:
        - Files
      summary: Confirm uploaded files
      description: >-
        Pass up to 100 confirmations after their signed PUTs succeed. JSON body
        limit: 1 MiB. Shared Vault checks permissions and storage, creates or
        updates artifacts, and schedules indexing. HTTP 200 may contain per-file
        failures; inspect every result. Native upload tokens expire after one
        hour. Completion is not idempotent: replay can create another version
        and repeat indexing. Inspect the destination after an uncertain result
        before retrying. Does not create filing items or wait for indexing.
      operationId: completeFileUpload
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/V2FileUploadComplete'
      responses:
        '200':
          description: Per-file results, including created/updated artifacts or errors.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2FileUploadCompleteResponse'
        '400':
          description: Invalid request input.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2CodedError'
        '401':
          description: Authentication required.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2CodedError'
        '403':
          description: Write permission required.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2CodedError'
        '404':
          description: Upload destination or owner not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2CodedError'
        '409':
          description: Resource state conflicts with this request.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2CodedError'
        '413':
          description: Request exceeds 1 MiB.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2CodedError'
        '415':
          description: Content-Type must be application/json.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2CodedError'
        '500':
          description: Unexpected server error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2CodedError'
        '503':
          description: Temporarily unavailable. Retry-After is in seconds.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2CodedError'
      security:
        - bearerAuth: []
components:
  schemas:
    V2FileUploadComplete:
      type: object
      properties:
        confirmations:
          type: array
          items:
            type: object
            properties:
              uploadToken:
                type: string
                description: Opaque token from init response
            required:
              - uploadToken
          minItems: 1
          maxItems: 100
          description: Confirmations for successfully uploaded files
      required:
        - confirmations
      additionalProperties: false
    V2FileUploadCompleteResponse:
      type: object
      properties:
        results:
          type: array
          items:
            type: object
            properties:
              uri:
                type: string
                minLength: 1
                description: Uploaded file URI
              success:
                type: boolean
                description: Whether the upload was confirmed successfully
              artifact:
                oneOf:
                  - $ref: '#/components/schemas/FileArtifact'
                  - $ref: '#/components/schemas/FolderArtifact'
                discriminator:
                  propertyName: nodeKind
                  mapping:
                    file: '#/components/schemas/FileArtifact'
                    folder: '#/components/schemas/FolderArtifact'
                description: Created/updated artifact (if successful)
              error:
                type: object
                properties:
                  code:
                    type: string
                    enum:
                      - PERMISSION_DENIED
                      - NOT_FOUND
                      - CONFLICT
                      - INTERNAL_ERROR
                      - INVALID_TOKEN
                      - EXPIRED
                    description: >-
                      Error code: INVALID_TOKEN (corrupt, malformed, or
                      mismatched token), EXPIRED (token has expired), NOT_FOUND
                      (file not in storage), CONFLICT (unexpected conflict),
                      PERMISSION_DENIED (user permissions changed),
                      INTERNAL_ERROR (unexpected error)
                  message:
                    type: string
                    description: Human-readable error message
                required:
                  - code
                  - message
                description: Error details (if failed)
            required:
              - uri
              - success
          description: Results for each confirmation
      required:
        - results
    V2CodedError:
      allOf:
        - $ref: '#/components/schemas/V2Error'
        - type: object
          properties:
            code:
              type: string
              minLength: 1
              description: Stable error code. Clients must tolerate unknown future codes.
            details:
              type: array
              items:
                type: object
                properties:
                  location:
                    type: string
                    enum:
                      - path
                      - query
                      - header
                      - body
                  path:
                    type: array
                    items:
                      type: string
                      maxLength: 64
                    maxItems: 12
                  code:
                    type: string
                    enum:
                      - required
                      - invalid_type
                      - invalid_value
                      - unknown_field
                  message:
                    type: string
                    minLength: 1
                    maxLength: 200
                required:
                  - location
                  - path
                  - code
                  - message
              minItems: 1
              maxItems: 20
              description: Bounded safe validation issues; may omit some invalid fields.
            requestId:
              type: string
              minLength: 1
              maxLength: 128
              description: >-
                Existing server correlation for this HTTP attempt, when
                available.
          required:
            - code
    FileArtifact:
      type: object
      properties:
        id:
          type: string
          description: Unique identifier for the artifact
        name:
          type: string
          description: Display name of the artifact
        parentId:
          type: string
          description: Parent artifact ID
        nodeKind:
          type: string
          enum:
            - file
        isIndexed:
          type: boolean
          description: Whether the artifact content has been indexed for search
        tags:
          $ref: '#/components/schemas/ArtifactTags'
        metadata:
          type: object
          properties:
            facetSchema:
              $ref: '#/components/schemas/ArtifactFacetSchema'
            description:
              type: string
              description: Human-readable artifact description
          additionalProperties:
            nullable: true
          description: >-
            Additional metadata for tracking batch processes and other
            information
        orgId:
          type: string
          default: ''
          description: Organization ID that owns this artifact
        createdAt:
          type: string
          format: date-time
          description: Timestamp when the artifact was created
        updatedAt:
          type: string
          format: date-time
          description: Timestamp when the artifact was last updated
        path:
          type: string
          description: Path of the artifact
        relativePath:
          type: string
          description: Relative path from parent folder (used for ZIP downloads)
        extractedTextPath:
          type: string
          description: Path in blob storage where extracted text is stored, if available
        stringFacet1:
          type: string
          description: >-
            Generic indexed string facet for application-defined labels (e.g.,
            serff_tracking_number). Meaning is defined at the application layer.
        stringFacet2:
          type: string
          description: >-
            Generic indexed string facet for application-defined labels. Meaning
            is defined at the application layer.
        stringFacet3:
          type: string
          description: >-
            Generic indexed string facet for application-defined labels. Meaning
            is defined at the application layer.
        createdBy:
          type: string
          description: User ID of the artifact creator
        sessionId:
          type: string
          description: >-
            Session ID this artifact belongs to (set for session-scoped
            artifacts)
        storageScopeId:
          type: string
          format: uuid
          description: Opaque storage scope that governs this artifact
        immutableContent:
          type: boolean
          description: Whether this artifact identity permanently names immutable content
        contentSha256:
          type: string
          pattern: ^sha256:[a-f0-9]{64}$
          description: Digest of immutable artifact content
        visibility:
          type: string
          enum:
            - org
            - private
            - session
            - run
            - public
          description: >-
            Artifact visibility mode: 'org' for team-wide (default), 'private'
            for owner-only, 'session' for session-inherited, 'run' for
            procedure-run scoped, 'public' for anyone with the link
        visibleTo:
          type: array
          items:
            type: string
          description: User IDs with explicit access to this artifact
        currentVersion:
          type: object
          properties:
            id:
              type: string
              format: uuid
              description: Artifact version ID
            versionNumber:
              type: integer
              minimum: 0
              exclusiveMinimum: true
              description: Monotonic version number
            contentSha256:
              type: string
              pattern: ^sha256:[a-f0-9]{64}$
              description: Digest of this artifact version content
            createdAt:
              type: string
              format: date-time
              description: Timestamp when this version was created
          required:
            - id
            - versionNumber
            - contentSha256
            - createdAt
          description: Current immutable content version, when available for this artifact
        type:
          type: string
          minLength: 1
          maxLength: 50
          description: Artifact classification; system-defined or custom
        data:
          anyOf:
            - $ref: '#/components/schemas/StoredFileMetadata'
            - $ref: '#/components/schemas/ExternalFileMetadata'
          description: File metadata associated with this artifact
      required:
        - id
        - name
        - nodeKind
        - isIndexed
        - createdAt
        - updatedAt
        - type
        - data
      description: File artifact with metadata
    FolderArtifact:
      type: object
      properties:
        id:
          type: string
          description: Unique identifier for the artifact
        name:
          type: string
          description: Display name of the artifact
        parentId:
          type: string
          description: Parent artifact ID
        nodeKind:
          type: string
          enum:
            - folder
        isIndexed:
          type: boolean
          description: Whether the artifact content has been indexed for search
        tags:
          $ref: '#/components/schemas/ArtifactTags'
        metadata:
          type: object
          properties:
            facetSchema:
              $ref: '#/components/schemas/ArtifactFacetSchema'
            description:
              type: string
              description: Human-readable artifact description
          additionalProperties:
            nullable: true
          description: >-
            Additional metadata for tracking batch processes and other
            information
        orgId:
          type: string
          default: ''
          description: Organization ID that owns this artifact
        createdAt:
          type: string
          format: date-time
          description: Timestamp when the artifact was created
        updatedAt:
          type: string
          format: date-time
          description: Timestamp when the artifact was last updated
        path:
          type: string
          description: Path of the artifact
        relativePath:
          type: string
          description: Relative path from parent folder (used for ZIP downloads)
        extractedTextPath:
          type: string
          description: Path in blob storage where extracted text is stored, if available
        stringFacet1:
          type: string
          description: >-
            Generic indexed string facet for application-defined labels (e.g.,
            serff_tracking_number). Meaning is defined at the application layer.
        stringFacet2:
          type: string
          description: >-
            Generic indexed string facet for application-defined labels. Meaning
            is defined at the application layer.
        stringFacet3:
          type: string
          description: >-
            Generic indexed string facet for application-defined labels. Meaning
            is defined at the application layer.
        createdBy:
          type: string
          description: User ID of the artifact creator
        sessionId:
          type: string
          description: >-
            Session ID this artifact belongs to (set for session-scoped
            artifacts)
        storageScopeId:
          type: string
          format: uuid
          description: Opaque storage scope that governs this artifact
        immutableContent:
          type: boolean
          description: Whether this artifact identity permanently names immutable content
        contentSha256:
          type: string
          pattern: ^sha256:[a-f0-9]{64}$
          description: Digest of immutable artifact content
        visibility:
          type: string
          enum:
            - org
            - private
            - session
            - run
            - public
          description: >-
            Artifact visibility mode: 'org' for team-wide (default), 'private'
            for owner-only, 'session' for session-inherited, 'run' for
            procedure-run scoped, 'public' for anyone with the link
        visibleTo:
          type: array
          items:
            type: string
          description: User IDs with explicit access to this artifact
        currentVersion:
          type: object
          properties:
            id:
              type: string
              format: uuid
              description: Artifact version ID
            versionNumber:
              type: integer
              minimum: 0
              exclusiveMinimum: true
              description: Monotonic version number
            contentSha256:
              type: string
              pattern: ^sha256:[a-f0-9]{64}$
              description: Digest of this artifact version content
            createdAt:
              type: string
              format: date-time
              description: Timestamp when this version was created
          required:
            - id
            - versionNumber
            - contentSha256
            - createdAt
          description: Current immutable content version, when available for this artifact
        type:
          type: string
          minLength: 1
          maxLength: 50
          description: Artifact classification; system-defined or custom
        data:
          type: object
          properties:
            id:
              type: string
              description: Unique identifier for the folder
            name:
              type: string
              description: Folder name
          required:
            - id
            - name
          description: Folder metadata associated with this artifact
      required:
        - id
        - name
        - nodeKind
        - isIndexed
        - createdAt
        - updatedAt
        - type
        - data
      description: Folder artifact
    V2Error:
      type: object
      properties:
        error:
          type: string
          minLength: 1
          description: Human-readable explanation of the failure.
      required:
        - error
    ArtifactTags:
      type: array
      items:
        type: string
      maxItems: 50
      default: []
      description: Canonical artifact tags
    ArtifactFacetSchema:
      type: object
      properties:
        stringFacet1:
          type: string
          description: Meaning of stringFacet1
        stringFacet2:
          type: string
          description: Meaning of stringFacet2
        stringFacet3:
          type: string
          description: Meaning of stringFacet3
      description: Meanings of indexed artifact facets
    StoredFileMetadata:
      type: object
      properties:
        id:
          type: string
          description: Unique identifier for the file
        name:
          type: string
          description: File name
        size:
          type: number
          description: File size in bytes
        pageCount:
          type: number
          description: Page count of the file
        totalPages:
          type: number
          description: Total pages reported by text extraction
        pageMapPath:
          type: string
          description: Storage path for extracted page metadata
        extractionMethod:
          type: string
          description: Method used to extract file text
        mimeType:
          type: string
          enum:
            - text/plain
            - text/markdown
            - text/vnd.mermaid
            - text/csv
            - application/json
            - application/yaml
            - application/xml
            - text/xml
            - text/html
            - text/css
            - text/javascript
            - application/javascript
            - application/typescript
            - text/x-python
            - text/x-rsl
            - application/pdf
            - application/vnd.openxmlformats-officedocument.spreadsheetml.sheet
            - application/vnd.ms-excel
            - application/vnd.ms-excel.sheet.macroEnabled.12
            - >-
              application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.macroEnabled.12
            - application/vnd.ms-excel.sheet.macroenabled.12
            - application/vnd.ms-excel.sheet.binary.macroEnabled.12
            - >-
              application/vnd.openxmlformats-officedocument.wordprocessingml.document
            - >-
              application/vnd.openxmlformats-officedocument.presentationml.presentation
            - application/vnd.ms-outlook
            - application/zip
            - application/x-tar
            - application/gzip
            - application/octet-stream
            - image/jpeg
            - image/png
            - image/gif
            - image/webp
            - image/svg+xml
            - audio/mpeg
            - audio/wav
            - audio/ogg
            - audio/mp4
            - audio/webm
            - video/mp4
            - video/webm
            - video/quicktime
            - video/x-msvideo
            - video/ogg
          description: MIME type of the file
        lastModified:
          type: number
          description: Last modified timestamp
        contentVersion:
          type: string
          description: >-
            Opaque content revision used to fence asynchronous indexing
            completion
        path:
          type: string
          description: Storage path
        storageInfo:
          oneOf:
            - type: object
              properties:
                location:
                  type: string
                  enum:
                    - gcs
                object:
                  type: string
                url:
                  type: string
              required:
                - location
                - object
            - type: object
              properties:
                location:
                  type: string
                  enum:
                    - filesystem
              required:
                - location
          description: Storage location information
        indexed:
          type: boolean
          description: Whether the artifact content has been indexed for search
      required:
        - id
        - name
        - size
        - mimeType
        - path
        - storageInfo
      description: Stored file metadata information
    ExternalFileMetadata:
      type: object
      properties:
        mimeType:
          type: string
          enum:
            - text/plain
            - text/markdown
            - text/vnd.mermaid
            - text/csv
            - application/json
            - application/yaml
            - application/xml
            - text/xml
            - text/html
            - text/css
            - text/javascript
            - application/javascript
            - application/typescript
            - text/x-python
            - text/x-rsl
            - application/pdf
            - application/vnd.openxmlformats-officedocument.spreadsheetml.sheet
            - application/vnd.ms-excel
            - application/vnd.ms-excel.sheet.macroEnabled.12
            - >-
              application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.macroEnabled.12
            - application/vnd.ms-excel.sheet.macroenabled.12
            - application/vnd.ms-excel.sheet.binary.macroEnabled.12
            - >-
              application/vnd.openxmlformats-officedocument.wordprocessingml.document
            - >-
              application/vnd.openxmlformats-officedocument.presentationml.presentation
            - application/vnd.ms-outlook
            - application/zip
            - application/x-tar
            - application/gzip
            - application/octet-stream
            - image/jpeg
            - image/png
            - image/gif
            - image/webp
            - image/svg+xml
            - audio/mpeg
            - audio/wav
            - audio/ogg
            - audio/mp4
            - audio/webm
            - video/mp4
            - video/webm
            - video/quicktime
            - video/x-msvideo
            - video/ogg
          description: MIME type, when known
        size:
          type: integer
          minimum: 0
          description: File size in bytes, when known
        lastModified:
          type: number
          description: Last modified timestamp, when known
        storageInfo:
          type: object
          properties:
            location:
              type: string
              enum:
                - external
            url:
              type: string
              format: uri
              description: Canonical URL of the external file
            provider:
              type: string
              minLength: 1
              maxLength: 100
              description: External file provider
            externalId:
              type: string
              minLength: 1
              maxLength: 2048
              description: Provider resource ID
            resourceKind:
              type: string
              minLength: 1
              maxLength: 100
              description: Provider-specific resource kind
            connectionId:
              type: string
              minLength: 1
              maxLength: 2048
              description: Effective connection used to access the resource
          required:
            - location
            - url
            - provider
          description: External file location information
      required:
        - storageInfo
      description: External file metadata information
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: 'Effective API key. Send Authorization: Bearer sk-eai-...'

````

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