All URIs are relative to https://api-sandbox.rebilly.com/organizations/{organizationId}
Method | HTTP request | Description |
---|---|---|
delete_invoice_item | DELETE /invoices/{id}/items/{itemId} | Delete an invoice item |
get_customer_upcoming_invoice_collection | GET /customers/{id}/upcoming-invoices | Retrieve customer's upcoming invoices |
get_invoice | GET /invoices/{id} | Retrieve an invoice |
get_invoice_collection | GET /invoices | Retrieve a list of invoices |
get_invoice_item | GET /invoices/{id}/items/{itemId} | Get an invoice item |
get_invoice_item_collection | GET /invoices/{id}/items | Retrieve invoice items |
get_invoice_transaction_allocation_collection | GET /invoices/{id}/transaction-allocations | Get transaction amounts allocated to an invoice |
post_invoice | POST /invoices | Create an invoice |
post_invoice_abandonment | POST /invoices/{id}/abandon | Abandon an invoice |
post_invoice_issuance | POST /invoices/{id}/issue | Issue an invoice |
post_invoice_item | POST /invoices/{id}/items | Create an invoice item |
post_invoice_recalculation | POST /invoices/{id}/recalculate | Recalculate an invoice |
post_invoice_reissuance | POST /invoices/{id}/reissue | Reissue an invoice |
post_invoice_transaction | POST /invoices/{id}/transaction | Apply a transaction to an invoice |
post_invoice_void | POST /invoices/{id}/void | Void an invoice |
put_invoice | PUT /invoices/{id} | Create or update an invoice with predefined ID |
put_invoice_item | PUT /invoices/{id}/items/{itemId} | Update an invoice item |
delete_invoice_item(id, item_id, opts)
Delete an invoice item
Delete an invoice item.
# load the gem
require 'rebilly_sdk'
# setup authorization
RebillySdk.configure do |config|
# Configure API key authorization: SecretApiKey
config.api_key['REB-APIKEY'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['REB-APIKEY'] = 'Bearer'
end
api_instance = RebillySdk::InvoicesApi.new
id = 'id_example' # String | The resource identifier string.
item_id = 'item_id_example' # String | The invoice item ID.
opts = {
organization_id: RebillySdk::ResourceId.new # ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead.
}
begin
#Delete an invoice item
api_instance.delete_invoice_item(id, item_id, opts)
rescue RebillySdk::ApiError => e
puts "Exception when calling InvoicesApi->delete_invoice_item: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
id | String | The resource identifier string. | |
item_id | String | The invoice item ID. | |
organization_id | ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead. | [optional] |
nil (empty response body)
- Content-Type: Not defined
- Accept: application/json
Array<Invoice> get_customer_upcoming_invoice_collection(id, opts)
Retrieve customer's upcoming invoices
Retrieve a list of upcoming invoices from the subscriptions which belong to. the given customer. The endpoint is temporary before upcoming invoices get a complete integration.
# load the gem
require 'rebilly_sdk'
# setup authorization
RebillySdk.configure do |config|
# Configure API key authorization: SecretApiKey
config.api_key['REB-APIKEY'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['REB-APIKEY'] = 'Bearer'
end
api_instance = RebillySdk::InvoicesApi.new
id = 'id_example' # String | The resource identifier string.
opts = {
organization_id: RebillySdk::ResourceId.new, # ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead.
expand: 'expand_example' # String | Expand a response to get a full related object included inside of the `_embedded` path in the response. It accepts a comma-separated list of objects to expand. See the [expand guide](https://api-reference.rebilly.com/#section/Expand-to-include-embedded-objects) for more info.
}
begin
#Retrieve customer's upcoming invoices
result = api_instance.get_customer_upcoming_invoice_collection(id, opts)
p result
rescue RebillySdk::ApiError => e
puts "Exception when calling InvoicesApi->get_customer_upcoming_invoice_collection: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
id | String | The resource identifier string. | |
organization_id | ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead. | [optional] |
expand | String | Expand a response to get a full related object included inside of the `_embedded` path in the response. It accepts a comma-separated list of objects to expand. See the expand guide for more info. | [optional] |
- Content-Type: Not defined
- Accept: application/json
Invoice get_invoice(id, opts)
Retrieve an invoice
Retrieve an invoice with specified identifier string.
# load the gem
require 'rebilly_sdk'
# setup authorization
RebillySdk.configure do |config|
# Configure API key authorization: SecretApiKey
config.api_key['REB-APIKEY'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['REB-APIKEY'] = 'Bearer'
end
api_instance = RebillySdk::InvoicesApi.new
id = 'id_example' # String | The resource identifier string.
opts = {
organization_id: RebillySdk::ResourceId.new, # ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead.
accept: 'application/json', # String | The response media type.
expand: 'expand_example' # String | Expand a response to get a full related object included inside of the `_embedded` path in the response. It accepts a comma-separated list of objects to expand. See the [expand guide](https://api-reference.rebilly.com/#section/Expand-to-include-embedded-objects) for more info.
}
begin
#Retrieve an invoice
result = api_instance.get_invoice(id, opts)
p result
rescue RebillySdk::ApiError => e
puts "Exception when calling InvoicesApi->get_invoice: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
id | String | The resource identifier string. | |
organization_id | ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead. | [optional] |
accept | String | The response media type. | [optional] [default to application/json] |
expand | String | Expand a response to get a full related object included inside of the `_embedded` path in the response. It accepts a comma-separated list of objects to expand. See the expand guide for more info. | [optional] |
ApplicationJWT, JWT, SecretApiKey
- Content-Type: Not defined
- Accept: application/json, application/pdf
Array<Invoice> get_invoice_collection(opts)
Retrieve a list of invoices
Retrieve a list of invoices.
# load the gem
require 'rebilly_sdk'
# setup authorization
RebillySdk.configure do |config|
# Configure API key authorization: SecretApiKey
config.api_key['REB-APIKEY'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['REB-APIKEY'] = 'Bearer'
end
api_instance = RebillySdk::InvoicesApi.new
opts = {
organization_id: RebillySdk::ResourceId.new, # ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead.
filter: 'filter_example', # String | The collection items filter requires a special format. Use \",\" for multiple allowed values. Use \";\" for multiple fields. See the [filter guide](https://api-reference.rebilly.com/#section/Using-filter-with-collections) for more options and examples about this format.
sort: ['sort_example'], # Array<String> | The collection items sort field and order (prefix with \"-\" for descending sort).
limit: 56, # Integer | The collection items limit.
offset: 56, # Integer | The collection items offset.
q: 'q_example', # String | The partial search of the text fields.
expand: 'expand_example' # String | Expand a response to get a full related object included inside of the `_embedded` path in the response. It accepts a comma-separated list of objects to expand. See the [expand guide](https://api-reference.rebilly.com/#section/Expand-to-include-embedded-objects) for more info.
}
begin
#Retrieve a list of invoices
result = api_instance.get_invoice_collection(opts)
p result
rescue RebillySdk::ApiError => e
puts "Exception when calling InvoicesApi->get_invoice_collection: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
organization_id | ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead. | [optional] |
filter | String | The collection items filter requires a special format. Use "," for multiple allowed values. Use ";" for multiple fields. See the filter guide for more options and examples about this format. | [optional] |
sort | Array<String> | The collection items sort field and order (prefix with "-" for descending sort). | [optional] |
limit | Integer | The collection items limit. | [optional] |
offset | Integer | The collection items offset. | [optional] |
q | String | The partial search of the text fields. | [optional] |
expand | String | Expand a response to get a full related object included inside of the `_embedded` path in the response. It accepts a comma-separated list of objects to expand. See the expand guide for more info. | [optional] |
ApplicationJWT, JWT, SecretApiKey
- Content-Type: Not defined
- Accept: application/json
InvoiceItem get_invoice_item(id, item_id, opts)
Get an invoice item
Get an invoice item.
# load the gem
require 'rebilly_sdk'
# setup authorization
RebillySdk.configure do |config|
# Configure API key authorization: SecretApiKey
config.api_key['REB-APIKEY'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['REB-APIKEY'] = 'Bearer'
end
api_instance = RebillySdk::InvoicesApi.new
id = 'id_example' # String | The resource identifier string.
item_id = 'item_id_example' # String | The invoice item ID.
opts = {
organization_id: RebillySdk::ResourceId.new # ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead.
}
begin
#Get an invoice item
result = api_instance.get_invoice_item(id, item_id, opts)
p result
rescue RebillySdk::ApiError => e
puts "Exception when calling InvoicesApi->get_invoice_item: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
id | String | The resource identifier string. | |
item_id | String | The invoice item ID. | |
organization_id | ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead. | [optional] |
- Content-Type: Not defined
- Accept: application/json
Array<InvoiceItem> get_invoice_item_collection(id, opts)
Retrieve invoice items
Retrieve an invoice items with specified invoice identifier string.
# load the gem
require 'rebilly_sdk'
# setup authorization
RebillySdk.configure do |config|
# Configure API key authorization: SecretApiKey
config.api_key['REB-APIKEY'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['REB-APIKEY'] = 'Bearer'
end
api_instance = RebillySdk::InvoicesApi.new
id = 'id_example' # String | The resource identifier string.
opts = {
organization_id: RebillySdk::ResourceId.new, # ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead.
limit: 56, # Integer | The collection items limit.
offset: 56, # Integer | The collection items offset.
expand: 'expand_example' # String | Expand a response to get a full related object included inside of the `_embedded` path in the response. It accepts a comma-separated list of objects to expand. See the [expand guide](https://api-reference.rebilly.com/#section/Expand-to-include-embedded-objects) for more info.
}
begin
#Retrieve invoice items
result = api_instance.get_invoice_item_collection(id, opts)
p result
rescue RebillySdk::ApiError => e
puts "Exception when calling InvoicesApi->get_invoice_item_collection: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
id | String | The resource identifier string. | |
organization_id | ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead. | [optional] |
limit | Integer | The collection items limit. | [optional] |
offset | Integer | The collection items offset. | [optional] |
expand | String | Expand a response to get a full related object included inside of the `_embedded` path in the response. It accepts a comma-separated list of objects to expand. See the expand guide for more info. | [optional] |
- Content-Type: Not defined
- Accept: application/json
Array<InvoiceTransactionAllocation> get_invoice_transaction_allocation_collection(id, opts)
Get transaction amounts allocated to an invoice
Get the precise amounts from a transaction allocated as invoice payments.
# load the gem
require 'rebilly_sdk'
# setup authorization
RebillySdk.configure do |config|
# Configure API key authorization: SecretApiKey
config.api_key['REB-APIKEY'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['REB-APIKEY'] = 'Bearer'
end
api_instance = RebillySdk::InvoicesApi.new
id = 'id_example' # String | The resource identifier string.
opts = {
organization_id: RebillySdk::ResourceId.new, # ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead.
limit: 56, # Integer | The collection items limit.
offset: 56 # Integer | The collection items offset.
}
begin
#Get transaction amounts allocated to an invoice
result = api_instance.get_invoice_transaction_allocation_collection(id, opts)
p result
rescue RebillySdk::ApiError => e
puts "Exception when calling InvoicesApi->get_invoice_transaction_allocation_collection: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
id | String | The resource identifier string. | |
organization_id | ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead. | [optional] |
limit | Integer | The collection items limit. | [optional] |
offset | Integer | The collection items offset. | [optional] |
Array<InvoiceTransactionAllocation>
- Content-Type: Not defined
- Accept: application/json
Invoice post_invoice(body, opts)
Create an invoice
Create an invoice.
# load the gem
require 'rebilly_sdk'
# setup authorization
RebillySdk.configure do |config|
# Configure API key authorization: SecretApiKey
config.api_key['REB-APIKEY'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['REB-APIKEY'] = 'Bearer'
end
api_instance = RebillySdk::InvoicesApi.new
body = RebillySdk::Invoice.new # Invoice | Invoice resource.
opts = {
organization_id: RebillySdk::ResourceId.new # ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead.
}
begin
#Create an invoice
result = api_instance.post_invoice(body, opts)
p result
rescue RebillySdk::ApiError => e
puts "Exception when calling InvoicesApi->post_invoice: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
body | Invoice | Invoice resource. | |
organization_id | ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead. | [optional] |
- Content-Type: application/json
- Accept: application/json
Invoice post_invoice_abandonment(id, opts)
Abandon an invoice
Abandon an invoice with specified identifier string.
# load the gem
require 'rebilly_sdk'
# setup authorization
RebillySdk.configure do |config|
# Configure API key authorization: SecretApiKey
config.api_key['REB-APIKEY'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['REB-APIKEY'] = 'Bearer'
end
api_instance = RebillySdk::InvoicesApi.new
id = 'id_example' # String | The resource identifier string.
opts = {
organization_id: RebillySdk::ResourceId.new # ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead.
}
begin
#Abandon an invoice
result = api_instance.post_invoice_abandonment(id, opts)
p result
rescue RebillySdk::ApiError => e
puts "Exception when calling InvoicesApi->post_invoice_abandonment: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
id | String | The resource identifier string. | |
organization_id | ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead. | [optional] |
- Content-Type: Not defined
- Accept: application/json
Invoice post_invoice_issuance(bodyid, opts)
Issue an invoice
Issue an invoice with specified identifier string. It must be in draft
status.
# load the gem
require 'rebilly_sdk'
# setup authorization
RebillySdk.configure do |config|
# Configure API key authorization: SecretApiKey
config.api_key['REB-APIKEY'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['REB-APIKEY'] = 'Bearer'
end
api_instance = RebillySdk::InvoicesApi.new
body = RebillySdk::InvoiceIssue.new # InvoiceIssue | InvoiceIssue resource.
id = 'id_example' # String | The resource identifier string.
opts = {
organization_id: RebillySdk::ResourceId.new # ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead.
}
begin
#Issue an invoice
result = api_instance.post_invoice_issuance(bodyid, opts)
p result
rescue RebillySdk::ApiError => e
puts "Exception when calling InvoicesApi->post_invoice_issuance: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
body | InvoiceIssue | InvoiceIssue resource. | |
id | String | The resource identifier string. | |
organization_id | ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead. | [optional] |
- Content-Type: application/json
- Accept: application/json
InvoiceItem post_invoice_item(bodyid, opts)
Create an invoice item
Create an invoice item.
# load the gem
require 'rebilly_sdk'
# setup authorization
RebillySdk.configure do |config|
# Configure API key authorization: SecretApiKey
config.api_key['REB-APIKEY'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['REB-APIKEY'] = 'Bearer'
end
api_instance = RebillySdk::InvoicesApi.new
body = RebillySdk::InvoiceItem.new # InvoiceItem | InvoiceItem resource.
id = 'id_example' # String | The resource identifier string.
opts = {
organization_id: RebillySdk::ResourceId.new # ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead.
}
begin
#Create an invoice item
result = api_instance.post_invoice_item(bodyid, opts)
p result
rescue RebillySdk::ApiError => e
puts "Exception when calling InvoicesApi->post_invoice_item: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
body | InvoiceItem | InvoiceItem resource. | |
id | String | The resource identifier string. | |
organization_id | ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead. | [optional] |
- Content-Type: application/json
- Accept: application/json
Invoice post_invoice_recalculation(id, opts)
Recalculate an invoice
Recalculate an invoice with specified identifier string. It will recalculate shipping rates, taxes, discounts. It is useful when coupon was revoked or customer redeemed coupon after invoice was issued and you want to apply it to this invoice.
# load the gem
require 'rebilly_sdk'
# setup authorization
RebillySdk.configure do |config|
# Configure API key authorization: SecretApiKey
config.api_key['REB-APIKEY'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['REB-APIKEY'] = 'Bearer'
end
api_instance = RebillySdk::InvoicesApi.new
id = 'id_example' # String | The resource identifier string.
opts = {
organization_id: RebillySdk::ResourceId.new # ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead.
}
begin
#Recalculate an invoice
result = api_instance.post_invoice_recalculation(id, opts)
p result
rescue RebillySdk::ApiError => e
puts "Exception when calling InvoicesApi->post_invoice_recalculation: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
id | String | The resource identifier string. | |
organization_id | ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead. | [optional] |
- Content-Type: Not defined
- Accept: application/json
Invoice post_invoice_reissuance(bodyid, opts)
Reissue an invoice
Reissue an invoice with specified identifier string. It must be issued. (status must be unpaid
or past-due
).
# load the gem
require 'rebilly_sdk'
# setup authorization
RebillySdk.configure do |config|
# Configure API key authorization: SecretApiKey
config.api_key['REB-APIKEY'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['REB-APIKEY'] = 'Bearer'
end
api_instance = RebillySdk::InvoicesApi.new
body = RebillySdk::InvoiceReissue.new # InvoiceReissue | InvoiceReissue resource.
id = 'id_example' # String | The resource identifier string.
opts = {
organization_id: RebillySdk::ResourceId.new # ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead.
}
begin
#Reissue an invoice
result = api_instance.post_invoice_reissuance(bodyid, opts)
p result
rescue RebillySdk::ApiError => e
puts "Exception when calling InvoicesApi->post_invoice_reissuance: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
body | InvoiceReissue | InvoiceReissue resource. | |
id | String | The resource identifier string. | |
organization_id | ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead. | [optional] |
- Content-Type: application/json
- Accept: application/json
Invoice post_invoice_transaction(bodyid, opts)
Apply a transaction to an invoice
Apply a transaction to an invoice. The invoice must be unpaid. The transaction must have a non-zero unused amount (not fully applied to other invoices).
# load the gem
require 'rebilly_sdk'
# setup authorization
RebillySdk.configure do |config|
# Configure API key authorization: SecretApiKey
config.api_key['REB-APIKEY'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['REB-APIKEY'] = 'Bearer'
end
api_instance = RebillySdk::InvoicesApi.new
body = RebillySdk::InvoiceTransaction.new # InvoiceTransaction | InvoiceTransaction resource.
id = 'id_example' # String | The resource identifier string.
opts = {
organization_id: RebillySdk::ResourceId.new # ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead.
}
begin
#Apply a transaction to an invoice
result = api_instance.post_invoice_transaction(bodyid, opts)
p result
rescue RebillySdk::ApiError => e
puts "Exception when calling InvoicesApi->post_invoice_transaction: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
body | InvoiceTransaction | InvoiceTransaction resource. | |
id | String | The resource identifier string. | |
organization_id | ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead. | [optional] |
- Content-Type: application/json
- Accept: application/json
Invoice post_invoice_void(id, opts)
Void an invoice
Void an invoice with specified identifier string.
# load the gem
require 'rebilly_sdk'
# setup authorization
RebillySdk.configure do |config|
# Configure API key authorization: SecretApiKey
config.api_key['REB-APIKEY'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['REB-APIKEY'] = 'Bearer'
end
api_instance = RebillySdk::InvoicesApi.new
id = 'id_example' # String | The resource identifier string.
opts = {
organization_id: RebillySdk::ResourceId.new # ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead.
}
begin
#Void an invoice
result = api_instance.post_invoice_void(id, opts)
p result
rescue RebillySdk::ApiError => e
puts "Exception when calling InvoicesApi->post_invoice_void: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
id | String | The resource identifier string. | |
organization_id | ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead. | [optional] |
- Content-Type: Not defined
- Accept: application/json
Invoice put_invoice(bodyid, opts)
Create or update an invoice with predefined ID
Create or update an invoice with predefined identifier string.
# load the gem
require 'rebilly_sdk'
# setup authorization
RebillySdk.configure do |config|
# Configure API key authorization: SecretApiKey
config.api_key['REB-APIKEY'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['REB-APIKEY'] = 'Bearer'
end
api_instance = RebillySdk::InvoicesApi.new
body = RebillySdk::Invoice.new # Invoice | Invoice resource.
id = 'id_example' # String | The resource identifier string.
opts = {
organization_id: RebillySdk::ResourceId.new # ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead.
}
begin
#Create or update an invoice with predefined ID
result = api_instance.put_invoice(bodyid, opts)
p result
rescue RebillySdk::ApiError => e
puts "Exception when calling InvoicesApi->put_invoice: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
body | Invoice | Invoice resource. | |
id | String | The resource identifier string. | |
organization_id | ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead. | [optional] |
- Content-Type: application/json
- Accept: application/json
InvoiceItem put_invoice_item(bodyiditem_id, opts)
Update an invoice item
Update an invoice item.
# load the gem
require 'rebilly_sdk'
# setup authorization
RebillySdk.configure do |config|
# Configure API key authorization: SecretApiKey
config.api_key['REB-APIKEY'] = 'YOUR API KEY'
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
#config.api_key_prefix['REB-APIKEY'] = 'Bearer'
end
api_instance = RebillySdk::InvoicesApi.new
body = RebillySdk::InvoiceItem.new # InvoiceItem | InvoiceItem resource.
id = 'id_example' # String | The resource identifier string.
item_id = 'item_id_example' # String | The invoice item ID.
opts = {
organization_id: RebillySdk::ResourceId.new # ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead.
}
begin
#Update an invoice item
result = api_instance.put_invoice_item(bodyiditem_id, opts)
p result
rescue RebillySdk::ApiError => e
puts "Exception when calling InvoicesApi->put_invoice_item: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
body | InvoiceItem | InvoiceItem resource. | |
id | String | The resource identifier string. | |
item_id | String | The invoice item ID. | |
organization_id | ResourceId | Organization identifier in scope of which need to perform request (if not specified, the default organization will be used). It is deprecated. Use servers with `/organizations/{organizationId}` base path instead. | [optional] |
- Content-Type: application/json
- Accept: application/json