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

# Publish Handoff



## OpenAPI

````yaml /openapi.json post /api/v1/brands/{brand_id}/brand-intelligence/native-create/{revision_id}/publish-handoff
openapi: 3.1.0
info:
  title: AITasker
  version: 0.1.0
servers: []
security: []
paths:
  /api/v1/brands/{brand_id}/brand-intelligence/native-create/{revision_id}/publish-handoff:
    post:
      tags:
        - SEO and Content Create
      summary: Publish Handoff
      operationId: >-
        publish_handoff_api_v1_brands__brand_id__brand_intelligence_native_create__revision_id__publish_handoff_post
      parameters:
        - name: brand_id
          in: path
          required: true
          schema:
            type: string
            format: uuid
            title: Brand Id
        - name: revision_id
          in: path
          required: true
          schema:
            type: string
            format: uuid
            title: Revision Id
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/NativeCreatePublishHandoffRequest'
      responses:
        '202':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/NativeCreatePublishHandoffResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - HTTPBearer: []
components:
  schemas:
    NativeCreatePublishHandoffRequest:
      properties:
        revisionId:
          type: string
          format: uuid
          title: Revisionid
        childContext:
          anyOf:
            - $ref: '#/components/schemas/NativeCreateChildContext'
            - type: 'null'
        idempotencyKey:
          type: string
          maxLength: 128
          minLength: 1
          title: Idempotencykey
        destinationId:
          type: string
          format: uuid
          title: Destinationid
        approved:
          type: boolean
          const: true
          title: Approved
        updateTarget:
          anyOf:
            - oneOf:
                - $ref: '#/components/schemas/NativeCreateWordPressPageUpdateTarget'
                - $ref: '#/components/schemas/NativeCreateKeystaticPageUpdateTarget'
              discriminator:
                propertyName: provider
                mapping:
                  keystatic:
                    $ref: '#/components/schemas/NativeCreateKeystaticPageUpdateTarget'
                  wordpress:
                    $ref: '#/components/schemas/NativeCreateWordPressPageUpdateTarget'
            - type: 'null'
          title: Updatetarget
      additionalProperties: false
      type: object
      required:
        - revisionId
        - idempotencyKey
        - destinationId
        - approved
      title: NativeCreatePublishHandoffRequest
    NativeCreatePublishHandoffResponse:
      properties:
        revisionId:
          type: string
          format: uuid
          title: Revisionid
        childContext:
          anyOf:
            - $ref: '#/components/schemas/NativeCreateChildContext'
            - type: 'null'
        handoffId:
          type: string
          format: uuid
          title: Handoffid
        destinationId:
          type: string
          format: uuid
          title: Destinationid
        teamId:
          type: string
          format: uuid
          title: Teamid
        teamTaskId:
          type: string
          format: uuid
          title: Teamtaskid
        publishTaskId:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Publishtaskid
        status:
          type: string
          enum:
            - needs_approval
            - queued
            - published
            - failed
          title: Status
        operation:
          type: string
          enum:
            - create_post
            - update_page
            - create_review_draft
          title: Operation
          default: create_post
        sourceUrl:
          anyOf:
            - type: string
              maxLength: 2083
              minLength: 1
              format: uri
            - type: 'null'
          title: Sourceurl
        reviewDraftUrl:
          anyOf:
            - type: string
              maxLength: 2083
              minLength: 1
              format: uri
            - type: 'null'
          title: Reviewdrafturl
        publicationStatus:
          anyOf:
            - type: string
              const: draft
            - type: 'null'
          title: Publicationstatus
        accessState:
          type: string
          enum:
            - available
            - restricted
            - erased
          title: Accessstate
        reused:
          type: boolean
          title: Reused
          default: false
      additionalProperties: false
      type: object
      required:
        - revisionId
        - handoffId
        - destinationId
        - teamId
        - teamTaskId
        - status
        - accessState
      title: NativeCreatePublishHandoffResponse
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    NativeCreateChildContext:
      properties:
        programRevisionId:
          type: string
          format: uuid
          title: Programrevisionid
        assetId:
          type: string
          format: uuid
          title: Assetid
        childRevisionId:
          type: string
          format: uuid
          title: Childrevisionid
      additionalProperties: false
      type: object
      required:
        - programRevisionId
        - assetId
        - childRevisionId
      title: NativeCreateChildContext
    NativeCreateWordPressPageUpdateTarget:
      properties:
        revisionId:
          type: string
          format: uuid
          title: Revisionid
        destinationId:
          type: string
          format: uuid
          title: Destinationid
        sourcePageRef:
          $ref: '#/components/schemas/OwnedPageRevisionRef'
        canonicalUrl:
          type: string
          maxLength: 2083
          minLength: 1
          format: uri
          title: Canonicalurl
        currentTitle:
          type: string
          maxLength: 500
          title: Currenttitle
        currentBody:
          type: string
          maxLength: 200000
          title: Currentbody
        currentContentSha256:
          type: string
          pattern: ^[0-9a-f]{64}$
          title: Currentcontentsha256
        preparedAt:
          type: string
          format: date-time
          title: Preparedat
        expiresAt:
          type: string
          format: date-time
          title: Expiresat
        proof:
          type: string
          maxLength: 4096
          minLength: 1
          title: Proof
        provider:
          type: string
          const: wordpress
          title: Provider
        postType:
          type: string
          enum:
            - posts
            - pages
          title: Posttype
        postId:
          type: integer
          minimum: 1
          title: Postid
        modifiedGmt:
          type: string
          maxLength: 100
          minLength: 1
          title: Modifiedgmt
      additionalProperties: false
      type: object
      required:
        - revisionId
        - destinationId
        - sourcePageRef
        - canonicalUrl
        - currentTitle
        - currentBody
        - currentContentSha256
        - preparedAt
        - expiresAt
        - proof
        - provider
        - postType
        - postId
        - modifiedGmt
      title: NativeCreateWordPressPageUpdateTarget
    NativeCreateKeystaticPageUpdateTarget:
      properties:
        revisionId:
          type: string
          format: uuid
          title: Revisionid
        destinationId:
          type: string
          format: uuid
          title: Destinationid
        sourcePageRef:
          $ref: '#/components/schemas/OwnedPageRevisionRef'
        canonicalUrl:
          type: string
          maxLength: 2083
          minLength: 1
          format: uri
          title: Canonicalurl
        currentTitle:
          type: string
          maxLength: 500
          title: Currenttitle
        currentBody:
          type: string
          maxLength: 200000
          title: Currentbody
        currentContentSha256:
          type: string
          pattern: ^[0-9a-f]{64}$
          title: Currentcontentsha256
        preparedAt:
          type: string
          format: date-time
          title: Preparedat
        expiresAt:
          type: string
          format: date-time
          title: Expiresat
        proof:
          type: string
          maxLength: 4096
          minLength: 1
          title: Proof
        provider:
          type: string
          const: keystatic
          title: Provider
        repo:
          type: string
          maxLength: 300
          minLength: 3
          title: Repo
        branch:
          type: string
          maxLength: 255
          minLength: 1
          title: Branch
        path:
          type: string
          maxLength: 1024
          minLength: 1
          title: Path
        blobSha:
          type: string
          pattern: ^[0-9a-f]{40}$
          title: Blobsha
      additionalProperties: false
      type: object
      required:
        - revisionId
        - destinationId
        - sourcePageRef
        - canonicalUrl
        - currentTitle
        - currentBody
        - currentContentSha256
        - preparedAt
        - expiresAt
        - proof
        - provider
        - repo
        - branch
        - path
        - blobSha
      title: NativeCreateKeystaticPageUpdateTarget
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
    OwnedPageRevisionRef:
      properties:
        brandId:
          type: string
          format: uuid
          title: Brandid
        sourceKind:
          type: string
          enum:
            - owned_page_capture
            - native_create_revision
          title: Sourcekind
        revisionId:
          type: string
          format: uuid
          title: Revisionid
        contentHash:
          type: string
          pattern: ^[0-9a-f]{64}$
          title: Contenthash
        canonicalUrl:
          type: string
          maxLength: 2083
          minLength: 1
          format: uri
          title: Canonicalurl
        evidenceRecordId:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Evidencerecordid
      additionalProperties: false
      type: object
      required:
        - brandId
        - sourceKind
        - revisionId
        - contentHash
        - canonicalUrl
      title: OwnedPageRevisionRef
  securitySchemes:
    HTTPBearer:
      type: http
      scheme: bearer

````