コンテンツにスキップ
Taylorz CRM Developers
Esc
↑↓移動↵開く⌘Jプレビュー

Create a draft quote

POST/api/v1/quotes/drafts
認証
AuthorizationOAuth2 アクセストークン · header必須

Authorization-code grant with PKCE. Clients are public and hold no secret. Discovery is published at /.well-known/oauth-authorization-server/api/auth.

スコープ:api.access
リクエストボディ
必須application/json
accountRecordIdstring必須
最小長 1 · 最大長 255
currencystring必須
^[A-Z]{3}$ に一致
exchangeRateobject
プロパティを表示
asOfstring<date>必須
^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))$ に一致
ratestring必須
^-?(?:0|[1-9]\d{0,15})(?:\.\d{1,8})?$ に一致
sourcestring必須
最小長 1 · 最大長 200
linesobject[]必須
最小項目数 1 · 最大項目数 500
プロパティを表示
object の配列
componentKindstring
デフォルト: "product"
許可される値:producthardwaresoftwareserviceoptionpackage
groupNamestring
最小長 1 · 最大長 120
pricingobject
デフォルト: {"method":"catalog"}
プロパティを表示
いずれか 1 つ:
object
methodstring必須
object
costEntryIdstring必須
最小長 1 · 最大長 255
markupstring必須
^-?(?:0|[1-9]\d{0,15})(?:\.\d{1,8})?$ に一致
methodstring必須
object
costEntryIdstring必須
最小長 1 · 最大長 255
marginstring必須
^-?(?:0|[1-9]\d{0,15})(?:\.\d{1,8})?$ に一致
methodstring必須
object
costEntryIdstring必須
最小長 1 · 最大長 255
downstreamMarginsstring[]必須
最小項目数 1 · 最大項目数 10
methodstring必須
retailPricestring必須
^-?(?:0|[1-9]\d{0,15})(?:\.\d{1,8})?$ に一致
object
methodstring必須
reasonstring必須
最小長 1 · 最大長 500
unitPricestring必須
^-?(?:0|[1-9]\d{0,15})(?:\.\d{1,8})?$ に一致
productIdstring必須
最小長 1 · 最大長 255
quantitystring必須
^-?(?:0|[1-9]\d{0,15})(?:\.\d{1,8})?$ に一致
schedulesobject[]必須
最小項目数 1 · 最大項目数 100
プロパティを表示
object の配列
いずれか 1 つ:
object
amountstring必須
^-?(?:0|[1-9]\d{0,15})(?:\.\d{1,8})?$ に一致
kindstring必須
startsOnstring<date>必須
^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))$ に一致
object
amountstring必須
^-?(?:0|[1-9]\d{0,15})(?:\.\d{1,8})?$ に一致
endsOnstring<date>
^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))$ に一致
intervalMonthsinteger必須
最小 1 · 最大 120
kindstring必須
startsOnstring<date>必須
^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))$ に一致
object
amountstring必須
^-?(?:0|[1-9]\d{0,15})(?:\.\d{1,8})?$ に一致
kindstring必須
milestoneLabelstring必須
最小長 1 · 最大長 200
startsOnstring<date>
^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))$ に一致
taxRatestring必須
^-?(?:0|[1-9]\d{0,15})(?:\.\d{1,8})?$ に一致
numberstring必須
最小長 1 · 最大長 120
orderDiscountobject
プロパティを表示
いずれか 1 つ:
object
basisstring必須
ratestring必須
^-?(?:0|[1-9]\d{0,15})(?:\.\d{1,8})?$ に一致
object
amountstring必須
^-?(?:0|[1-9]\d{0,15})(?:\.\d{1,8})?$ に一致
basisstring必須
pricingDatestring<date>必須
^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))$ に一致
recordIdstring必須
最小長 1 · 最大長 255
レスポンス
201

The draft and its version

idstring必須
最小長 1 · 最大長 255
totalsQuoteTotals必須
プロパティを表示
currencystring必須
^[A-Z]{3}$ に一致
discountstring必須
^-?(?:0|[1-9]\d{0,15})(?:\.\d{1,8})?$ に一致
linesobject[]必須
プロパティを表示
object の配列
discountstring必須
^-?(?:0|[1-9]\d{0,15})(?:\.\d{1,8})?$ に一致
netstring必須
^-?(?:0|[1-9]\d{0,15})(?:\.\d{1,8})?$ に一致
taxstring必須
^-?(?:0|[1-9]\d{0,15})(?:\.\d{1,8})?$ に一致
taxRatestring必須
^-?(?:0|[1-9]\d{0,15})(?:\.\d{1,8})?$ に一致
subtotalstring必須
^-?(?:0|[1-9]\d{0,15})(?:\.\d{1,8})?$ に一致
taxstring必須
^-?(?:0|[1-9]\d{0,15})(?:\.\d{1,8})?$ に一致
taxableAmountstring必須
^-?(?:0|[1-9]\d{0,15})(?:\.\d{1,8})?$ に一致
totalstring必須
^-?(?:0|[1-9]\d{0,15})(?:\.\d{1,8})?$ に一致
versioninteger必須
最小 1 · 最大 2147483647
versionIdstring必須
最小長 1 · 最大長 255
400

The request body, query or parameters were refused

codestring必須
許可される値:invalid_inputnot_foundconflictforbidden
detailany
errorstring必須
reasonstring
401

The access token is missing, invalid or revoked

errorstring必須
403

The tenant's module is off, or the token's scope or the member's role does not permit the action

codestring必須
許可される値:invalid_inputnot_foundconflictforbidden
detailany
errorstring必須
reasonstring
404

No such record, or none the caller may read

codestring必須
許可される値:invalid_inputnot_foundconflictforbidden
detailany
errorstring必須
reasonstring
409

The operation conflicts with the current state

codestring必須
許可される値:invalid_inputnot_foundconflictforbidden
detailany
errorstring必須
reasonstring
413

The request exceeds the route's body limit

errorstring必須
500

An unexpected failure

errorstring必須
リクエスト
curl -X POST '/api/v1/api/v1/quotes/drafts' \
  -H 'Authorization: Bearer YOUR_ACCESS_TOKEN' \
  -H 'Accept: application/json' \
  -H 'Content-Type: application/json' \
  -d '{
  "accountRecordId": "string",
  "currency": "string",
  "exchangeRate": {
    "asOf": "2019-08-24",
    "rate": "string",
    "source": "string"
  },
  "lines": [
    {
      "componentKind": "product",
      "groupName": "string",
      "pricing": {
        "method": "catalog"
      },
      "productId": "string",
      "quantity": "string",
      "schedules": [
        {
          "amount": "string",
          "kind": "one_time",
          "startsOn": "2019-08-24"
        }
      ],
      "taxRate": "string"
    }
  ],
  "number": "string",
  "orderDiscount": {
    "basis": "rate",
    "rate": "string"
  },
  "pricingDate": "2019-08-24",
  "recordId": "string"
}'
レスポンス
{
  "id": "string",
  "totals": {
    "currency": "string",
    "discount": "string",
    "lines": [
      {
        "discount": "string",
        "net": "string",
        "tax": "string",
        "taxRate": "string"
      }
    ],
    "subtotal": "string",
    "tax": "string",
    "taxableAmount": "string",
    "total": "string"
  },
  "version": 1,
  "versionId": "string"
}

このページは役に立ちましたか?