API Docs
/
No Results Found
Credit-Notes

Credit-Notes

Credit notes are created when a refund is to be made to a customer. A credit note object allows you to keep track of all credit note related information.

Attribute

creditnote_id
string
Unique ID of the credit note generated by the server.
creditnote_number
string
Unique number generated (starts with CN) which will be displayed in the interface and credit notes.
date
string
The date on which credit note is raised.
status
string
Status of the credit note. This can be open, closed or void.
customer_id
string
Customer ID of the customer for whom the credit note is raised.
customer_name
string
Name of the customer to whom the credit note is raised.
custom_fields
array
Additional fields for the Credit-Notes.
Show Sub-Attributes arrow
index
integer
Index of the custom field. It can hold any value from 1 to 10.
value
string
Value of the Custom Field
label
string
Label of the Custom Field
data_type
string
Data type of the custom field.
reference_number
string
Reference number generated for the payment. A string of your choice can also be used as the reference number.
email
string
Email address of the customer.
total
double
Total credits raised in this credit note.
balance
double
The unapplied credits.
creditnote_items
array
List of items involved in the credit note. This contains item_id, description, quantity, price and item_total.
Show Sub-Attributes arrow
item_id
string
Unique string generated for the item to which a refund is to be made.
description
string
A small description about the item.
code
string
Unique code for the creditnote line item.
tags
array
Show Sub-Attributes arrow
tag_id
long
ID of the Tag
tag_option_id
long
Id of the Tag Option
item_custom_fields
array
Custom fields for a item.
Show Sub-Attributes arrow
label
string
Label of the Custom Field
value
string
Value of the Custom Field
name
string
Name of the credit
type
integer
Type of the creditnote line item.
account_id
string
Unique ID to denote the account.
account_name
string
Name of the account.
quantity
int32
Quantity of the item included.
tax_id
string
Unique to denote the tax associate dto the creditnote
price
double
The price of the item included.
item_total
double
Total credits raised by this item. This would be the multiplicative product of item price and quantity.
invoices
array
List of invoices for which the credit note has been raised. This contains invoice_id and amount.
Show Sub-Attributes arrow
invoice_id
string
Invoice ID of the required invoice.
invoice_number
string
Invoice number of the required invoice.
amount
double
Amount paid for the invoice.
taxes
array
Taxes associated wit the subscription.
Show Sub-Attributes arrow
tax_id
string
Unique to denote the tax associate dto the creditnote
tax_name
string
Unique name for tax.
tax_amount
string
Tax amount applied to the subscription.
currency_code
string
Customer's currency code. This currency code is used in credit notes.
currency_symbol
string
Customer's currency symbol.
created_time
string
Time at which the credit note was created.
updated_time
string
Time at which the credit note details were last updated.
template_id
string
Unique ID of the creditnote template
template_name
string
Name of the default template of the creditnote.
notes
string
A short note for the credit note.
terms
string
Terms & condition to be displayed in the credit note.

Example

{ "creditnote_id": "90300000072369", "creditnote_number": "CN-29", "date": "2016-06-05", "status": "open", "customer_id": "903000000000099", "customer_name": "Bowman Furniture", "custom_fields": [ { "index": 1, "value": "string", "label": "string", "data_type": "text" } ], "reference_number": "INV-384", "email": "benjamin.george@bowmanfurniture.com", "total": 450, "balance": 10, "creditnote_items": [ { "item_id": "90300000081501", "description": "prorated amount for items", "code": "basic-monthly", "tags": [ { "tag_id": 0, "tag_option_id": 0 } ], "item_custom_fields": [ { "label": "string", "value": "string" } ], "name": "Basic Monthly", "type": 1, "account_id": "903000000000388", "account_name": "Sales", "quantity": 1, "tax_id": "903000000000356", "price": 100, "item_total": 100 } ], "invoices": [ { "invoice_id": "90300000079426", "invoice_number": "INV-384", "amount": 450 } ], "taxes": [ { "tax_id": "903000000000356", "tax_name": "Basic Tax", "tax_amount": "2.50" } ], "currency_code": "USD", "currency_symbol": "$", "created_time": "2016-06-05T02:30:08-0700", "updated_time": "2016-06-05T02:30:08-0700", "template_id": "90300000001336", "template_name": "Standard Template", "notes": "Offer for the referral", "terms": "" }

Create a credit note

Details of an existing creditnote.
oauthscope : ZohoSubscriptions.creditnotes.CREATE

Arguments

customer_id
string
(Required)
Customer ID of the customer for whom the credit note is raised.
contact_persons
array
Contact Persons associated with the credit note.
date
string
(Required)
The date on which credit note is raised.
exchange_rate
string
Exchange rate for the currency associated with the customer.
creditnote_items
array
(Required)
List of items involved in the credit note. This contains item_id, description, quantity, price and item_total.
Show Sub-Attributes arrow
description
string
A small description about the item.
code
string
(Required)
Unique code for the creditnote line item.
account_id
string
Unique ID to denote the account.
quantity
int32
(Required)
Quantity of the item included.
tags
array
Show Sub-Attributes arrow
tag_id
long
ID of the Tag
tag_option_id
long
Id of the Tag Option
item_custom_fields
array
Custom fields for a item.
Show Sub-Attributes arrow
label
string
Label of the Custom Field
value
string
Value of the Custom Field
tax_id
string
Unique to denote the tax associate dto the creditnote
tax_exemption_id
string
Sales Tax GST only
Unique ID of the tax exemption.
tax_exemption_code
string
Sales Tax GST only
Unique code of the tax exemption.
price
double
(Required)
The price of the item included.
creditnote_number
string
(Required)
Unique number generated (starts with CN) which will be displayed in the interface and credit notes.
ignore_auto_number_generation
boolean
Set to true if you need to provide your own credit note number.
reference_number
string
Reference number generated for the payment. A string of your choice can also be used as the reference number.
custom_fields
array
Additional fields for the Credit-Notes.
Show Sub-Attributes arrow
label
string
Label of the Custom Field
value
string
Value of the Custom Field
notes
string
A short note for the credit note.
terms
string
Terms & condition to be displayed in the credit note.
template_id
string
Unique ID of the creditnote template

Request Example

Click to copy
$ curl https://subscriptions.zoho.com/api/v1/creditnotes -X POST -H "X-com-zoho-subscriptions-organizationid: 10234695" -H "Content-Type: application/json;charset=UTF-8" -H "Authorization: Zoho-oauthtoken 1000.41d9f2cfbd1b7a8f9e314b7aff7bc2d1.8fcc9810810a216793f385b9dd6e125f" -d '{"field":"value","field":"value"}'

Body Parameters

Click to copy
{ "customer_id": "903000000000099", "contact_persons": [ "903000006532" ], "date": "2016-06-05", "exchange_rate": "5.5", "creditnote_items": [ { "description": "prorated amount for items", "code": "basic-monthly", "account_id": "903000000000388", "quantity": 1, "tags": [ { "tag_id": 0, "tag_option_id": 0 } ], "item_custom_fields": [ { "label": "string", "value": "string" } ], "tax_id": "903000000000356", "tax_exemption_id": "903000006345", "tax_exemption_code": "GST FREE", "price": 100 } ], "creditnote_number": "CN-29", "ignore_auto_number_generation": false, "reference_number": "INV-384", "custom_fields": [ { "label": "string", "value": "string" } ], "notes": "Offer for the referral", "terms": "", "template_id": "90300000001336" }

Response Example

{ "code": 0, "message": "Credit Note created successfully.", "credit_note": { "creditnote_id": "90300000072369", "creditnote_number": "CN-29", "date": "2016-06-05", "status": "open", "customer_id": "903000000000099", "customer_name": "Bowman Furniture", "custom_fields": [ { "index": 1, "value": "string", "label": "string", "data_type": "text" } ], "reference_number": "INV-384", "email": "benjamin.george@bowmanfurniture.com", "total": 450, "balance": 10, "creditnote_items": [ { "item_id": "90300000081501", "description": "prorated amount for items", "code": "basic-monthly", "tags": [ { "tag_id": 0, "tag_option_id": 0 } ], "item_custom_fields": [ { "label": "string", "value": "string" } ], "name": "Basic Monthly", "type": 1, "account_id": "903000000000388", "account_name": "Sales", "quantity": 1, "tax_id": "903000000000356", "price": 100, "item_total": 100 } ], "invoices": [ { "invoice_id": "90300000079426", "invoice_number": "INV-384", "amount": 450 } ], "taxes": [ { "tax_id": "903000000000356", "tax_name": "Basic Tax", "tax_amount": "2.50" } ], "currency_code": "USD", "currency_symbol": "$", "created_time": "2016-06-05T02:30:08-0700", "updated_time": "2016-06-05T02:30:08-0700", "template_id": "90300000001336", "template_name": "Standard Template", "notes": "Offer for the referral", "terms": "" } }

Retreive a credit note

Details of an existing creditnote.
oauthscope : ZohoSubscriptions.creditnotes.READ

Request Example

Click to copy
$ curl https://subscriptions.zoho.com/api/v1/creditnotes/{creditnote_id} -H "X-com-zoho-subscriptions-organizationid: 10234695" -H "Authorization: Zoho-oauthtoken 1000.41d9f2cfbd1b7a8f9e314b7aff7bc2d1.8fcc9810810a216793f385b9dd6e125f"

Response Example

{ "code": 0, "message": "success", "credit_note": { "creditnote_id": "90300000072369", "creditnote_number": "CN-29", "date": "2016-06-05", "status": "open", "customer_id": "903000000000099", "customer_name": "Bowman Furniture", "custom_fields": [ { "index": 1, "value": "string", "label": "string", "data_type": "text" } ], "reference_number": "INV-384", "email": "benjamin.george@bowmanfurniture.com", "total": 450, "balance": 10, "creditnote_items": [ { "item_id": "90300000081501", "description": "prorated amount for items", "code": "basic-monthly", "tags": [ { "tag_id": 0, "tag_option_id": 0 } ], "item_custom_fields": [ { "label": "string", "value": "string" } ], "name": "Basic Monthly", "type": 1, "account_id": "903000000000388", "account_name": "Sales", "quantity": 1, "tax_id": "903000000000356", "price": 100, "item_total": 100 } ], "invoices": [ { "invoice_id": "90300000079426", "invoice_number": "INV-384", "amount": 450 } ], "taxes": [ { "tax_id": "903000000000356", "tax_name": "Basic Tax", "tax_amount": "2.50" } ], "currency_code": "USD", "currency_symbol": "$", "created_time": "2016-06-05T02:30:08-0700", "updated_time": "2016-06-05T02:30:08-0700", "template_id": "90300000001336", "template_name": "Standard Template", "notes": "Offer for the referral", "terms": "" } }

Delete a credit note

Delete an existing credit note.
oauthscope : ZohoSubscriptions.creditnotes.DELETE

Request Example

Click to copy
$ curl https://subscriptions.zoho.com/api/v1/creditnotes/{creditnote_id} -X DELETE -H "X-com-zoho-subscriptions-organizationid: 10234695" -H "Authorization: Zoho-oauthtoken 1000.41d9f2cfbd1b7a8f9e314b7aff7bc2d1.8fcc9810810a216793f385b9dd6e125f"

Response Example

{ "code": 0, "message": "The credit note has been deleted." }

Email a credit note

Email a credit note.
oauthscope : ZohoSubscriptions.creditnotes.CREATE

Arguments

to_mail_ids
array
(Required)
The email IDs to which the credit note is to be mailed.
cc_mail_ids
array
The email IDs that have to be copied when the credit note is to be mailed.
subject
string
(Required)
The subject of the email.
body
string
(Required)
The body of the email.

Request Example

Click to copy
$ curl https://subscriptions.zoho.com/api/v1/creditnotes/{creditnote_id}/email -X POST -H "X-com-zoho-subscriptions-organizationid: 10234695" -H "Content-Type: application/json;charset=UTF-8" -H "Authorization: Zoho-oauthtoken 1000.41d9f2cfbd1b7a8f9e314b7aff7bc2d1.8fcc9810810a216793f385b9dd6e125f" -d '{"field":"value","field":"value"}'

Body Parameters

Click to copy
{ "to_mail_ids": [ "benjamin.george@bowmanfurniture.com", "paul@bowmanfurniture.com" ], "cc_mail_ids": [ "accounts@bowmanfurniture.com" ], "subject": "Credit note for subscription.", "body": "Please find attached the credit note for your subscription." }

Response Example

{ "code": 0, "message": "Your creditnote has been sent." }

Void a credit note

Details of an existing creditnote.
oauthscope : ZohoSubscriptions.creditnotes.CREATE

Request Example

Click to copy
$ curl https://subscriptions.zoho.com/api/v1/creditnotes/{creditnote_id}/void -X POST -H "X-com-zoho-subscriptions-organizationid: 10234695" -H "Authorization: Zoho-oauthtoken 1000.41d9f2cfbd1b7a8f9e314b7aff7bc2d1.8fcc9810810a216793f385b9dd6e125f"

Response Example

{ "code": 0, "message": "The credit note has been marked as void." }

Open a voided credit note

Convert a voided credit note to open.
oauthscope : ZohoSubscriptions.creditnotes.CREATE

Request Example

Click to copy
$ curl https://subscriptions.zoho.com/api/v1/creditnotes/{creditnote_id}/converttoopen -X POST -H "X-com-zoho-subscriptions-organizationid: 10234695" -H "Authorization: Zoho-oauthtoken 1000.41d9f2cfbd1b7a8f9e314b7aff7bc2d1.8fcc9810810a216793f385b9dd6e125f"

Response Example

{ "code": 0, "message": "Status of the credit note has been changed to open." }

Apply Credits to Multiple Invoices

To associate a creditnote to multiple invoices.
oauthscope : ZohoSubscriptions.creditnotes.CREATE

Arguments

invoices
array
(Required)
List of invoices for which the credit note has been raised. This contains invoice_id and amount.
Show Sub-Attributes arrow
invoice_id
string
(Required)
Invoice ID of the required invoice.
amount_applied
(Required)
Credit amount to be applied to the invoice.

Request Example

Click to copy
$ curl https://subscriptions.zoho.com/api/v1/creditnotes/{creditnote_id}/invoices -X POST -H "X-com-zoho-subscriptions-organizationid: 10234695" -H "Content-Type: application/json;charset=UTF-8" -H "Authorization: Zoho-oauthtoken 1000.41d9f2cfbd1b7a8f9e314b7aff7bc2d1.8fcc9810810a216793f385b9dd6e125f" -d '{"field":"value","field":"value"}'

Body Parameters

Click to copy
{ "invoices": [ { "invoice_id": "90300000079426", "amount_applied": 450 } ] }

Response Example

{ "code": 0, "message": "Credits have been applied to the invoice(s).", "invoices": [ { "invoice_id": "90300000079426", "amount_applied": 450 }, {...}, {...} ] }