---
title: "Create a vendor credit"
method: POST
path: "/v3/vendor-credits"
tags: ["vendor-credits"]
---

# Create a vendor credit

`POST /v3/vendor-credits`

Create a vendor credit.

With a vendor credit, you can adjust the amount that you owe a vendor.

See [Vendor credits](https://developer.bill.com/docs/ap-vendor-credits) in the Guides section for more information, sample requests, and responses.

## Headers

- `sessionId` string, nullable — API session ID generated with `/v3/login`
- `devKey` string, nullable — Developer key generated with your BILL developer account

## Request body

- CreateVendorCreditRequestDto — Create a vendor credit
  - `vendorId` string, required — BILL-generated ID of the vendor. The value begins with `009`.
  - `referenceNumber` string, required — User-generated vendor credit number. This value can be in your chosen number scheme.
  - `creditDate` string, date, required — Vendor credit issued date. This value is in the `yyyy-MM-dd` format.
  - `description` string — Vendor credit description
  - `applyToChartOfAccountId` string — BILL-generated ID of the chart of accounts used when the vendor credit is applied to a bill payment. The value begins with `0ca`.
  - `applyToBankAccountId` string — BILL-generated ID of the bank account used when the vendor credit is applied to a bill payment. The value begins with `bac`. **Note**: You can set only one of `applyToChartOfAccountId` or `applyToBankAccountId`.
  - `vendorCreditLineItems` CreateVendorCreditLineItemDto[], required — Vendor credit line item information
    - `description` string — Vendor credit line item description
    - `amount` number, required — Vendor credit line item amount. For a vendor credit in an international currency (not USD), this value is in the local currency.
    - `classifications` object — General ledger classifications information for the vendor credit line item
      - `chartOfAccountId` string — BILL-generated ID of the chart of accounts. The value begins with `0ca`.
      - `accountingClassId` string — BILL-generated ID of the accounting class. The value begins with `cls`.
      - `departmentId` string — BILL-generated ID of the department. The value begins with `0de`.
      - `jobId` string — BILL-generated ID of the job. The value begins with `job`.
      - `locationId` string — BILL-generated ID of the location. The value begins with `loc`.
      - `itemId` string — BILL-generated ID of the item. The value begins with `0ii`.
      - `employeeId` string — BILL-generated ID of the employee. The value begins with `emp`.
      - `customerId` string — BILL-generated ID of the customer. The value begins with `0cu`.

## Response `201`

Create a vendor credit response

- VendorCreditResponseDto — VendorCredit response Dto.
  - `id` string — BILL-generated ID of the vendor credit. The value begins with `vcr`.
  - `vendorId` string — BILL-generated ID of the vendor. The value begins with `009`.
  - `referenceNumber` string — User-generated vendor credit number. This value can be in your chosen number scheme.
  - `creditDate` string, date — Vendor credit issued date. This value is in the `yyyy-MM-dd` format.
  - `description` string — Vendor credit description
  - `archived` boolean — Set as `true` if the vendor credit is archived
  - `applyToChartOfAccountId` string — BILL-generated ID of the chart of accounts used when the vendor credit is applied to a bill payment. The value begins with `0ca`.
  - `applyToBankAccountId` string — BILL-generated ID of the bank account used when the vendor credit is applied to a bill payment. The value begins with `bac`. **Note**: You can set only one of `applyToChartOfAccountId` or `applyToBankAccountId`.
  - `amount` number — Vendor credit amount
  - `appliedAmount` number — Vendor credit amount applied to invoices
  - `status` 'FULLY_APPLIED' | 'NOT_APPLIED' | 'PARTIALLY_APPLIED' | 'IN_PROCESS' | 'UNDEFINED' — Vendor credit status.
  - `createdTime` string, date-time — Vendor credit created time
  - `updatedTime` string, date-time — Vendor credit updated time
  - `vendorCreditLineItems` VendorCreditLineItemResponseDto[] — Vendor credit line item information
    - `id` string — BILL-generated ID of the vendor credit line item. The value begins with `vci`.
    - `description` string — Vendor credit line item description
    - `amount` number — Vendor credit line item amount. For a vendor credit in an international currency (not USD), this value is in the local currency.
    - `classifications` object — General ledger classifications information for the vendor credit line item
      - `chartOfAccountId` string — BILL-generated ID of the chart of accounts. The value begins with `0ca`.
      - `accountingClassId` string — BILL-generated ID of the accounting class. The value begins with `cls`.
      - `departmentId` string — BILL-generated ID of the department. The value begins with `0de`.
      - `jobId` string — BILL-generated ID of the job. The value begins with `job`.
      - `locationId` string — BILL-generated ID of the location. The value begins with `loc`.
      - `itemId` string — BILL-generated ID of the item. The value begins with `0ii`.
      - `employeeId` string — BILL-generated ID of the employee. The value begins with `emp`.
      - `customerId` string — BILL-generated ID of the customer. The value begins with `0cu`.

## Other responses

- `4XX` — List of errors.
- `5XX` — List of errors.

---

[API](https://skmtc.net/bill/apis/bill-v3-api.md) · [All operations](https://skmtc.net/bill/apis/bill-v3-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/bill/bill-v3-api/versions/0483350c434e/schema)
