Top

Vendor Payments

List vendor payments
GET /vendorpayments
List all the payments made to your vendor.
Get a vendor payment
GET /vendorpayments/:payment_id
Get the details of a vendor payment.
Create a vendor payment
POST /vendorpayments
Create a payment made to your vendor and you can also apply them to bills either partially or fully.
Update a vendor payment
PUT /vendorpayments/:payment_id
Update an existing vendor payment. You can also modify the amount applied to the bills.
Delete a vendor payment
DELETE /vendorpayments/:payment_id
Delete an existing vendor payment.

List vendor payments

GET  /vendorpayments

List all the payments made to your vendor.

Parameters

vendor_name string
[100]
Search payments by vendor name.
Variants: vendor_name_startswith and vendor_name_contains
reference_number string
[100]
Search payments by reference number.
Variants: reference_number_startswith and reference_number_contains
date string
[yyyy-MM-dd]
Search payments by payment made date.
Variants: date_start, date_end, date_before and date_after
amount double Search payments by payment amount.
Variants: amount_less_than, amount_less_equals, amount_greater_than and amount_greater_equals
payment_mode string
[100]
Search payments by payment mode.
Variants: payment_mode_startswith and payment_mode_contains
vendor_id string Search payments by vendor id.
bill_id string Search payments by bill id.
filter_by string Filter payments by mode.
Allowed Values: PaymentMode.All, PaymentMode.Check, PaymentMode.Cash, PaymentMode.BankTransfer, PaymentMode.Paypal, PaymentMode.CreditCard, PaymentMode.GoogleCheckout, PaymentMode.Credit, PaymentMode.Authorizenet, PaymentMode.BankRemittance, PaymentMode.Payflowpro and PaymentMode.Others
search_text string
[100]
Search payments by reference number or vendor name or payment description.
sort_column string Sort the payment list.
Allowed Values: vendor_name, date, reference_number, amount and balance
notes string
[100]
Search payments by notes.
Variants: notes_startswith and notes_contains

Sample Response


Status: 200 OK
Content Type: application/json;charset=UTF-8
{
  "code": 0,
  "message": "success",
  "vendorpayments": [
    {
      "payment_id": "460000000053219",
      "vendor_id": "460000000026049",
      "vendor_name": "Bowman and Co",
      "payment_mode": "Stripe",
      "description": "",
      "date": "2013-10-07",
      "reference_number": "REF#912300",
      "exchange_rate": 1.00,
      "amount": 500.00,
      "paid_through_account_id": "460000000000358",
      "paid_through_account_name": "Undeposited Funds",
      "balance": 350.00
    },
    {
      "payment_id": "460000000042059",
      "vendor_id": "460000000038029",
      "vendor_name": "Will Cooper",
      "payment_mode": "Cash",
      "description": "",
      "date": "2013-09-11",
      "reference_number": "43218995",
      "exchange_rate": 1.23,
      "amount": 31.25,
      "paid_through_account_id": "460000000000358",
      "paid_through_account_name": "Undeposited Funds",
      "balance": 0.00
    }
  ],
  "page_context": {
    "page": 1,
    "per_page": 200,
    "has_more_page": false,
    "report_name": "Payments Made",
    "applied_filter": "PaymentMode.All",
    "sort_column": "date",
    "sort_order": "D"
  }
}

Get a vendor payment

GET  /vendorpayments/:payment_id

Get the details of a vendor payment.

Sample Response


Status: 200 OK
Content Type: application/json;charset=UTF-8
{
  "code": 0,
  "message": "success",
  "vendorpayment": {
    "payment_id": "460000000053219",
    "vendor_id": "460000000026049",
    "vendor_name": "Bowman and Co",
    "payment_mode": "Stripe",
    "description": "",
    "date": "2013-10-07",
    "reference_number": "REF#912300",
    "exchange_rate": 1.00,
    "amount": 500.00,
    "currency_symbol": "$",
    "paid_through_account_id": "460000000000358",
    "paid_through_account_name": "Undeposited Funds",
    "bills": [
      {
        "bill_number": "1000",
        "bill_payment_id": "460000000053221",
        "bill_id": "460000000053199",
        "total": 450.00,
        "balance": 300.00,
        "amount_applied": 150.00,
        "date": "2013-10-07",
        "due_date": "2013-10-07"
      }
    ]
  }
}

Create a vendor payment

POST  /vendorpayments

Create a payment made to your vendor and you can also apply them to bills either partially or fully.

Request attributes

vendor_id string ID of the vendor.
bills array Individual bill payment details as array.
bill_id string ID of the bill the payment is to be applied.
amount_applied double Amount applied to the bill.
date string
[yyyy-MM-dd]
Date the payment is made.
exchange_rate double Exchange rate of the currency.
amount* double Payment amount made to the vendor.
paid_through_account_id string ID of the cash/ bank account the payment is made.

Sample Request

{
  "vendor_id": "460000000026049",
  "bills": [
    {
      "bill_id": "460000000053199",
      "amount_applied": 150.00
    }
  ],
  "payment_mode": "Stripe",
  "description": "",
  "date": "2013-10-07",
  "reference_number": "REF#912300",
  "exchange_rate": 1.00,
  "amount": 500.00,
  "paid_through_account_id": "460000000000358"
}

Sample Response


Status: 201 Created
Content Type: application/json;charset=UTF-8
{
  "code": 0,
  "message": "The payment made to the vendor has been recorded",
  "vendorpayment": {
    "payment_id": "460000000053219",
    "vendor_id": "460000000026049",
    "vendor_name": "Bowman and Co",
    "payment_mode": "Stripe",
    "description": "",
    "date": "2013-10-07",
    "reference_number": "REF#912300",
    "exchange_rate": 1.00,
    "amount": 500.00,
    "currency_symbol": "$",
    "paid_through_account_id": "460000000000358",
    "paid_through_account_name": "Undeposited Funds",
    "bills": [
      {
        "bill_number": "1000",
        "bill_payment_id": "460000000053221",
        "bill_id": "460000000053199",
        "total": 450.00,
        "balance": 300.00,
        "amount_applied": 150.00,
        "date": "2013-10-07",
        "due_date": "2013-10-07"
      }
    ]
  }
}

Update a vendor payment

PUT  /vendorpayments/:payment_id

Update an existing vendor payment. You can also modify the amount applied to the bills.

Request attributes

vendor_id string ID of the vendor.
bills array Individual bill payment details as array.
bill_payment_id string Id of individual bill payment, for which the applied amount to be updated.
bill_id string ID of the bill the payment is to be applied.
amount_applied double Amount applied to the bill.
date string
[yyyy-MM-dd]
Date the payment is made.
exchange_rate double Exchange rate of the currency.
amount* double Payment amount made to the vendor.
paid_through_account_id string ID of the cash/ bank account the payment is made.

Sample Request

{
      "vendor_id": "460000000026049",
      "bills": [
        {
          "bill_payment_id": "460000000053221",
          "bill_id": "460000000053199",
          "amount_applied": 150.00
        }
      ],
      "payment_mode": "Stripe",
      "description": "",
      "date": "2013-10-07",
      "reference_number": "REF#9123001",
      "exchange_rate": 1.00,
      "amount": 500.00,
      "paid_through_account_id": "460000000000358"
    }

Sample Response


Status: 200 OK
Content Type: application/json;charset=UTF-8
{
      "code": 0,
      "message": "The details of the payment made to the vendor has been updated",
      "vendorpayment": {
        "payment_id": "460000000053219",
        "vendor_id": "460000000026049",
        "vendor_name": "Bowman and Co",
        "payment_mode": "Stripe",
        "description": "",
        "date": "2013-10-07",
        "reference_number": "REF#9123001",
        "exchange_rate": 1.00,
        "amount": 500.00,
        "currency_symbol": "$",
        "paid_through_account_id": "460000000000358",
        "paid_through_account_name": "Undeposited Funds",
        "bills": [
          {
            "bill_number": "1000",
            "bill_payment_id": "460000000053221",
            "bill_id": "460000000053199",
            "total": 450.00,
            "balance": 300.00,
            "amount_applied": 150.00,
            "date": "2013-10-07",
            "due_date": "2013-10-07"
          }
        ]
      }
    }

Delete a vendor payment

DELETE  /vendorpayments/:payment_id

Delete an existing vendor payment.

Sample Response


Status: 200 OK
Content Type: application/json;charset=UTF-8
{
  "code": 0,
  "message": "The payment has been deleted."
}