---
title: "POST /ticket/id/{id}/linkSalesOrder"
method: POST
path: "/ticket/id/{id}/linkSalesOrder"
tags: ["ticket"]
---

# POST /ticket/id/{id}/linkSalesOrder

`POST /ticket/id/{id}/linkSalesOrder`

## Request

- Base URL: `https://www.weclapp.com/api/nullapi/v2`
- URL: `https://www.weclapp.com/api/nullapi/v2/ticket/id/{id}/linkSalesOrder`
- Auth: API key in header `AuthenticationToken`
- TypeScript: <https://skmtc.dev/weclapp/apis/weclapp-api/docs/ticket/id/:id/linkSalesOrder/post.ts> (a function with typed inputs; its response is checked against the schema)

## Path parameters

- `id` string, required

## Request body

- object
  - `salesOrderId` integer, required
  - `taskIdToOrderItemId` object

## Response `200`

linkSalesOrder response

- object
  - `result` Ticket
    - `id` string
    - `version` string
    - `assignedPoolingGroupId` string
    - `assignedUserId` string
    - `billable` boolean
    - `billableStatus` boolean
    - `ccEmailAddresses` string
    - `contactId` string
    - `contractId` string
    - `createdDate` integer
    - `customAttributes` CustomAttribute[]
      - `attributeDefinitionId` string
      - `booleanValue` boolean
      - `dateValue` integer
      - `entityId` string
      - `entityReferences` EntityReference[]
        - `entityId` string
        - `entityName` string
      - `numberValue` string, number
      - `selectedValueId` string
      - `selectedValues` OnlyId[]
        - `id` string
      - `stringValue` string
    - `description` string
    - `disableEmailTemplates` boolean
    - `email` string
    - `entityReferences` EntityReference[]
      - `entityId` string
      - `entityName` string
    - `finishedDate` integer
    - `firstName` string
    - `followUpDate` integer
    - `invoicingStatus` 'INVOICED' | 'NOT_INVOICED' | 'PARTLY_INVOICED'
    - `isTemplate` boolean
    - `language` string
    - `lastModifiedDate` integer
    - `lastName` string
    - `legacyArticleId` string
    - `legacyTimeAndMaterialTicket` boolean
    - `mail2TicketId` string
    - `mobilePhoneNumber` string
    - `note` string
    - `partyId` string
    - `performanceRecordedStatus` 'NOT_PERFORMANCE_RECORDABLE' | 'ON_PERFORMANCE_RECORD' | 'PERFORMANCE_RECORDABLE' | 'PERFORMANCE_RECORDED'
    - `phoneNumber` string
    - `publicPageExpirationDate` integer
    - `publicPageUuid` string
    - `resolvedYourIssue` boolean
    - `responsibleUserId` string
    - `room` string
    - `salesOrderId` string
    - `solutionDueDate` integer
    - `subject` string
    - `tags` string[]
    - `ticketCategoryId` string
    - `ticketChannelId` string
    - `ticketNumber` string
    - `ticketPriorityId` string, required
    - `ticketRating` 'STARS_1' | 'STARS_2' | 'STARS_3' | 'STARS_4' | 'STARS_5'
    - `ticketRatingComment` string
    - `ticketRatingDate` integer
    - `ticketServiceLevelAgreementId` string
    - `ticketStatusId` string, required
    - `ticketTypeId` string
    - `watchers` OnlyId[]
      - `id` string

## Other responses

- `default`: error response

## Changes

- **2026-11-07** `0e021229755d`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/weclapp/apis/weclapp-api/changes/ticket/id/:id/linkSalesOrder/post.md)

---

[API](https://skmtc.dev/weclapp/apis/weclapp-api.md) - [All operations](https://skmtc.dev/weclapp/apis/weclapp-api/llms.txt) - [OpenAPI document](https://skmtc.dev/weclapp/apis/weclapp-api/revisions/0e021229755d?raw)
