@datafire/rebilly
v6.0.0
Published
DataFire integration for Rebilly
Downloads
2
Readme
@datafire/rebilly
Client library for Rebilly
Installation and Usage
npm install --save @datafire/rebilly
let rebilly = require('@datafire/rebilly').create({
JWT: "",
PublishableApiKey: "",
SecretApiKey: ""
});
.then(data => {
console.log(data);
});
Description
Introduction
The Rebilly API is built on HTTP. Our API is RESTful. It has predictable resource URLs. It returns HTTP response codes to indicate errors. It also accepts and returns JSON in the HTTP body. You can use your favorite HTTP/REST library for your programming language to use Rebilly's API, or you can use one of our SDKs (currently available in PHP and Javascript).
We have other APIs that are also available. Every action from our app is supported by an API which is documented and available for use so that you may automate any workflows necessary. This document contains the most commonly integrated resources.
Authentication
When you sign up for an account, you are given your first secret API key. You can generate additional API keys, and delete API keys (as you may need to rotate your keys in the future). You authenticate to the Rebilly API by providing your secret key in the request header.
Rebilly offers three forms of authentication: secret key, publishable key, JSON Web Tokens, and public signature key.
- Secret API key: used for requests made from the server side. Never share these keys. Keep them guarded and secure.
- Publishable API key: used for requests from the client side. For now can only be used to create a Payment Token and a File token.
- JWT: short lifetime tokens that can be assigned a specific expiration time.
Never share your secret keys. Keep them guarded and secure.
SDKs
Rebilly offers a Javascript SDK and a PHP SDK to help interact with the API. However, no SDK is required to use the API.
Rebilly also offers FramePay, a client-side iFrame-based solution to help create payment tokens while minimizing PCI DSS compliance burdens and maximizing the customizability. FramePay is interacting with the payment tokens creation operation.
Javascript SDK
The Javascript SDK is maintained within Github, and contains the installation and usage instructions.
PHP SDK
For all PHP SDK examples provided in these docs you will need to configure the $client
.
You may do it like this:
$client = new Rebilly\Client([
'apiKey' => 'YourApiKeyHere',
'baseUrl' => 'https://api.rebilly.com',
]);
Using filter with Collections
Rebilly provides collections filtering. You can use ?filter
param on collection to define which records should be shown in the response.
Here is filter format description:
Fields and values in filter are separated with
:
:?filter=firstName:John
.Fields in filter are separated with
;
:?filter=firstName:John;lastName:Doe
.You can use multiple values using
,
as values separator:?filter=firstName:John,Bob
.To negate the filter use
!
:?filter=firstName:!John
. Note that you can negate multiple values like this:?filter=firstName:!John,Bob
. This filter rule will exclude all Johns and Bobs from the response.You can use range filters like this:
?filter=amount:1..10
.You can use gte (greater than or equals) filter like this:
?filter=amount:1..
, or lte (less than or equals) than filter like this:?filter=amount:..10
.You can create some predefined values lists and use them in filter:
?filter=firstName:@yourListName
. You can also exclude list values:?filter=firstName:!@yourListName
Expand to Include Embedded Objects
Rebilly provides the ability to pre-load additional objects with a request.
You can use ?expand
param on most requests to expand
and include embedded objects within the
_embedded
property of the response.
The _embedded
property contains an array of
objects keyed by the expand parameter value(s).
You may expand multiple objects by passing them as comma-separated to the expand value like so:
?expand=recentInvoice,customer
And in the response, you would see:
"_embedded": [
"recentInvoice": {...},
"customer": {...}
]
Expand may be utilitized not only on GET
requests but also on PATCH
, POST
, PUT
requests too.
Getting Started Guide
Rebilly's API has over 300 operations. That's more than you'll need to implement your use cases. If you have a use case you would like to implement, please consult us for feedback on the best API operations for the task.
Our getting started guide will demonstrate a basic order form use case. It will allow us to highlight core resources in Rebilly that will be helpful for many other use cases too.
Within 25 minutes, you'll have sent API requests (via our console) to create a subscription order.
Click here to visit our API Guide Tutorial.
Actions
Get3DSecureCollection
Retrieve a list of ThreeDSecure entries
rebilly.Get3DSecureCollection({}, context)
Input
- input
object
- limit
integer
: The collection items limit - offset
integer
: The collection items offset - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- limit
Output
- output
array
- items ThreeDSecure
Post3DSecure
Create a ThreeDSecure entry
rebilly.Post3DSecure({
"body": {
"enrolled": "",
"enrollmentEci": "",
"customerId": null,
"gatewayAccountId": null,
"paymentCardId": null,
"websiteId": null,
"currency": null,
"amount": 0
}
}, context)
Input
- input
object
- body required ThreeDSecure
- Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output ThreeDSecure
Get3DSecure
Retrieve a ThreeDSecure entry with specified identifier string
rebilly.Get3DSecure({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output ThreeDSecure
GetAttachmentCollection
Retrieve a list of Attachments
rebilly.GetAttachmentCollection({}, context)
Input
- input
object
- limit
integer
: The collection items limit - offset
integer
: The collection items offset - filter
string
: The collection items filter requires a special format. - q
string
: The partial search of the text fields. - expand
string
: Expand a response to get a full related object included inside - fields
string
: Limit the returned fields to the list specified, separated by comma. Note that id is always returned. - sort
array
: The collection items sort field and order (prefix with "-" for descending sort). - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- limit
Output
- output
array
- items Attachment
PostAttachment
Create an Attachment
rebilly.PostAttachment({
"body": {
"fileId": "",
"relatedId": "",
"relatedType": ""
}
}, context)
Input
- input
object
- body required Attachment
- Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output Attachment
DeleteAttachment
Delete the Attachment with predefined identifier string
rebilly.DeleteAttachment({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
Output schema unknown
GetAttachment
Retrieve a Attachment with specified identifier string
rebilly.GetAttachment({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output Attachment
PutAttachment
Update the Attachment with predefined ID
rebilly.PutAttachment({
"body": {
"fileId": "",
"relatedId": "",
"relatedType": ""
},
"id": ""
}, context)
Input
- input
object
- body required Attachment
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output Attachment
GetAuthenticationOption
Read current authentication options
rebilly.GetAuthenticationOption({}, context)
Input
- input
object
- Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- Organization-Id
Output
- output
array
- items AuthenticationOptions
PutAuthenticationOption
Change options
rebilly.PutAuthenticationOption({
"body": {}
}, context)
Input
- input
object
- body required AuthenticationOptions
- Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output AuthenticationOptions
GetAuthenticationTokenCollection
Retrieve a list of auth tokens
rebilly.GetAuthenticationTokenCollection({}, context)
Input
- input
object
- limit
integer
: The collection items limit - offset
integer
: The collection items offset - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- limit
Output
- output
array
- items AuthenticationToken
PostAuthenticationToken
Login a customer
rebilly.PostAuthenticationToken({
"body": {}
}, context)
Input
- input
object
- body required AuthenticationToken
- Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output AuthenticationToken
DeleteAuthenticationToken
Logout a customer
rebilly.DeleteAuthenticationToken({
"token": ""
}, context)
Input
- input
object
- token required
string
: The token identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- token required
Output
Output schema unknown
GetAuthenticationTokenVerification
Verify an authentication token
rebilly.GetAuthenticationTokenVerification({
"token": ""
}, context)
Input
- input
object
- token required
string
: The token identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- token required
Output
- output AuthenticationToken
PostAuthenticationTokenExchange
Exchange Authentication Token for JWT
It will also invalidate an Authentication Token by default (so it can only be exchanged once).
rebilly.PostAuthenticationTokenExchange({
"body": {},
"token": ""
}, context)
Input
- input
object
- body required CustomerJWT
- token required
string
: The token identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output CustomerJWT
GetBankAccountCollection
Retrieve a list of Bank Accounts
rebilly.GetBankAccountCollection({}, context)
Input
- input
object
- limit
integer
: The collection items limit - offset
integer
: The collection items offset - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- limit
Output
- output
array
- items BankAccount
PostBankAccount
Create a Bank Account
rebilly.PostBankAccount({
"body": null
}, context)
Input
- input
object
- Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- Organization-Id
Output
- output BankAccount
GetBankAccount
Retrieve a Bank Account with specified identifier string
rebilly.GetBankAccount({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output BankAccount
PatchBankAccount
Update bank account's values except for the account number and routing number
rebilly.PatchBankAccount({
"id": ""
}, context)
Input
- input
object
- body
object
- accountType
string
(values: checking, savings, other): Bank's Account type. - address: The Address.
- address
string
: The contact street address - address2
string
: The contact street address (second line) - city
string
: The contact city - country
string
: The contact country ISO Alpha-2 code - emails ContactEmails
- firstName
string
: The contact first name - hash
string
: A hash that can be used to compare multiple contacts for identical attribute values - lastName
string
: The contact last name - organization
string
: The contact organization - phoneNumbers ContactPhoneNumbers
- postalCode
string
: The contact postal code - region
string
: The contact region (state)
- address
- bankName
string
: Bank's name. - customFields ResourceCustomFields
- accountType
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- body
Output
- output BankAccount
PutBankAccount
Create or update a BankAccount with predefined identifier string
rebilly.PutBankAccount({
"body": null,
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output BankAccount
PostBankAccountDeactivation
Deactivate a Bank Account
rebilly.PostBankAccountDeactivation({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output BankAccount
GetBlacklistCollection
Retrieve a list of blacklists
rebilly.GetBlacklistCollection({}, context)
Input
- input
object
- limit
integer
: The collection items limit - offset
integer
: The collection items offset - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- limit
Output
- output
array
- items Blacklist
PostBlacklist
Create a blacklist
rebilly.PostBlacklist({
"body": {
"type": "",
"value": ""
}
}, context)
Input
- input
object
- body required Blacklist
- Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output Blacklist
DeleteBlacklist
Delete a blacklist with predefined identifier string
rebilly.DeleteBlacklist({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
Output schema unknown
GetBlacklist
Retrieve a blacklist with specified identifier string
rebilly.GetBlacklist({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output Blacklist
PutBlacklist
Create a blacklist with predefined identifier string
rebilly.PutBlacklist({
"body": {
"type": "",
"value": ""
},
"id": ""
}, context)
Input
- input
object
- body required Blacklist
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output Blacklist
GetContactCollection
Retrieve a list of contacts. This may be useful when giving the customer a choice between previous addresses they've used before.
rebilly.GetContactCollection({}, context)
Input
- input
object
- limit
integer
: The collection items limit - offset
integer
: The collection items offset - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- limit
Output
- output
array
- items Contact
PostContact
Contacts are created automatically by data passed to the contact-related hashes within the customer, invoice, payment instrument (like payment card), subscriptions, and more.
rebilly.PostContact({
"body": {}
}, context)
Input
- input
object
- body required Contact
- Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output Contact
DeleteContact
Delete a contact with predefined identifier string
rebilly.DeleteContact({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
Output schema unknown
GetContact
Retrieve a contact with specified identifier string
rebilly.GetContact({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output Contact
PutContact
Create or update a contact with predefined identifier string
rebilly.PutContact({
"body": {},
"id": ""
}, context)
Input
- input
object
- body required Contact
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output Contact
GetCouponCollection
Retrieve a list of coupons
rebilly.GetCouponCollection({}, context)
Input
- input
object
- limit
integer
: The collection items limit - offset
integer
: The collection items offset - filter
string
: The collection items filter requires a special format. - q
string
: The partial search of the text fields. - sort
array
: The collection items sort field and order (prefix with "-" for descending sort). - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- limit
Output
- output
array
- items Coupon
PostCoupon
Create a coupon
rebilly.PostCoupon({
"body": {
"discount": {},
"issuedTime": ""
}
}, context)
Input
- input
object
- body required Coupon
- Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output Coupon
GetCouponRedemptionCollection
Retrieve a list of coupon redemptions
rebilly.GetCouponRedemptionCollection({}, context)
Input
- input
object
- limit
integer
: The collection items limit - offset
integer
: The collection items offset - filter
string
: The collection items filter requires a special format. - q
string
: The partial search of the text fields. - sort
array
: The collection items sort field and order (prefix with "-" for descending sort). - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- limit
Output
- output
array
- items CouponRedemption
PostCouponRedemption
Redeem a coupon
rebilly.PostCouponRedemption({
"body": {}
}, context)
Input
- input
object
- body required CouponRedemption
- Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output CouponRedemption
GetCouponRedemption
Retrieve a coupon redemption with specified identifier string
rebilly.GetCouponRedemption({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output CouponRedemption
PostCouponRedemptionCancellation
Cancel a coupon redemption
rebilly.PostCouponRedemptionCancellation({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
Output schema unknown
GetCoupon
Retrieve a coupon with specified redemption code string
rebilly.GetCoupon({
"redemptionCode": ""
}, context)
Input
- input
object
- redemptionCode required
string
: The Coupon's redemption code - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- redemptionCode required
Output
- output Coupon
PutCoupon
Create or update a coupon with predefined redemption code
rebilly.PutCoupon({
"body": {
"discount": {},
"issuedTime": ""
},
"redemptionCode": ""
}, context)
Input
- input
object
- body required Coupon
- redemptionCode required
string
: The Coupon's redemption code - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output Coupon
PostCouponExpiration
Set a coupon's expiry time with the specified redemption code. The expiredTime of a coupon must be greater than its issuedTime. This cannot be performed on expired coupons.
rebilly.PostCouponExpiration({
"redemptionCode": ""
}, context)
Input
- input
object
- body CouponExpiration
- redemptionCode required
string
: The coupon's redemption code - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output Coupon
GetCredentialCollection
Retrieve a list of credentials
rebilly.GetCredentialCollection({}, context)
Input
- input
object
- limit
integer
: The collection items limit - offset
integer
: The collection items offset - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- limit
Output
- output
array
- items Credential
PostCredential
Create a credential
rebilly.PostCredential({
"body": {
"username": "",
"password": "",
"customerId": ""
}
}, context)
Input
- input
object
- body required Credential
- Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output Credential
DeleteCredential
Delete a credential with predefined identifier string
rebilly.DeleteCredential({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
Output schema unknown
GetCredential
Retrieve a credential with specified identifier string
rebilly.GetCredential({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output Credential
PutCredential
Create or update a credential with predefined identifier string
rebilly.PutCredential({
"body": {
"username": "",
"password": "",
"customerId": ""
},
"id": ""
}, context)
Input
- input
object
- body required Credential
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output Credential
GetCustomFieldCollection
Retrieve a schema of Custom Fields for the given resource type
rebilly.GetCustomFieldCollection({
"resource": ""
}, context)
Input
- input
object
- resource required
string
(values: customers, payment-cards, subscriptions, transactions, websites, contacts, products, plans): The resource type string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- resource required
Output
- output
array
: The list of custom fields- items CustomField
GetCustomField
Retrieve a schema of the given Custom Field for the given resource type
rebilly.GetCustomField({
"resource": "",
"name": ""
}, context)
Input
- input
object
- resource required
string
(values: customers, payment-cards, subscriptions, transactions, websites, contacts, products, plans): The resource type string - name required
string
: The custom field's identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- resource required
Output
- output CustomField
PutCustomField
Create or alter a schema of the given Custom Field for the given resource type.
rebilly.PutCustomField({
"body": {
"type": ""
},
"resource": "",
"name": ""
}, context)
Input
- input
object
- body required CustomField
- resource required
string
(values: customers, payment-cards, subscriptions, transactions, websites, contacts, products, plans): The resource type string - name required
string
: The custom field's identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output CustomField
GetCustomerTimelineCustomEventTypeCollection
Retrieve a list of customer timeline custom event types
rebilly.GetCustomerTimelineCustomEventTypeCollection({}, context)
Input
- input
object
- limit
integer
: The collection items limit - offset
integer
: The collection items offset - filter
string
: The collection items filter requires a special format. - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- limit
Output
- output
array
PostCustomerTimelineCustomEventType
Create Customer Timeline custom event type
rebilly.PostCustomerTimelineCustomEventType({
"body": {
"name": ""
}
}, context)
Input
- input
object
- body required CustomerTimelineCustomEvent
- Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output CustomerTimelineCustomEvent
GetCustomerTimelineCustomEventType
Retrieve customer timeline custom event type
rebilly.GetCustomerTimelineCustomEventType({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output CustomerTimelineCustomEvent
GetCustomerTimelineEventCollection
Retrieve a list of customer timeline messages for all customers
rebilly.GetCustomerTimelineEventCollection({}, context)
Input
- input
object
- limit
integer
: The collection items limit - offset
integer
: The collection items offset - filter
string
: The collection items filter requires a special format. - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- limit
Output
- output
array
- items CustomerTimeline
GetCustomerCollection
Retrieve a list of customers
rebilly.GetCustomerCollection({}, context)
Input
- input
object
- limit
integer
: The collection items limit - offset
integer
: The collection items offset - filter
string
: The collection items filter requires a special format. - q
string
: The partial search of the text fields. - expand
string
: Expand a response to get a full related object included inside - fields
string
: Limit the returned fields to the list specified, separated by comma. Note that id is always returned. - sort
array
: The collection items sort field and order (prefix with "-" for descending sort). - Accept
string
(values: application/json, text/csv): The response media type - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- limit
Output
- output
array
- items Customer
PostCustomer
Create a customer without a predefined ID. The customer's primary address will be used as the default address for payment instruments, subscriptions and invoices if none are provided.
If you wish to create the customer with a predefined
ID (which we recommend to prevent duplication), you
may use our PUT
request described below.
Read our guide to preventing duplicates to understand more.
rebilly.PostCustomer({
"body": {}
}, context)
Input
- input
object
- body required Customer
- Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output Customer
DeleteCustomer
Merge one duplicate customer to another target customer and delete the former.
rebilly.DeleteCustomer({
"targetCustomerId": "",
"id": ""
}, context)
Input
- input
object
- targetCustomerId required
string
: The customer idendifier to get the data of the deleted duplicate customer - id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- targetCustomerId required
Output
Output schema unknown
GetCustomer
Retrieve a customer with specified identifier string
rebilly.GetCustomer({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output Customer
PutCustomer
Create or update (upsert) a customer with predefined identifier string. Read our guide to preventing duplicates to understand more.
rebilly.PutCustomer({
"body": {},
"id": ""
}, context)
Input
- input
object
- body required Customer
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output Customer
DeleteCustomerLeadSource
Delete a Lead Source that belongs to a certain customer
rebilly.DeleteCustomerLeadSource({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
Output schema unknown
GetCustomerLeadSource
Retrieve a Lead Source of given customer
rebilly.GetCustomerLeadSource({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output LeadSource
PutCustomerLeadSource
Create a Lead Source for a customer
rebilly.PutCustomerLeadSource({
"body": null,
"id": ""
}, context)
Input
- input
object
- body required LeadSource
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output LeadSource
GetCustomerTimelineCollection
Retrieve a list of customer timeline messages
rebilly.GetCustomerTimelineCollection({
"id": ""
}, context)
Input
- input
object
- limit
integer
: The collection items limit - offset
integer
: The collection items offset - filter
string
: The collection items filter requires a special format. - id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- limit
Output
- output
array
- items CustomerTimeline
PostCustomerTimeline
Create a customer Timeline comment or custom defined event
rebilly.PostCustomerTimeline({
"body": {},
"id": ""
}, context)
Input
- input
object
- body required CustomerTimeline
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output CustomerTimeline
DeleteCustomerTimeline
Delete a Customer Timeline message with predefined identifier string
rebilly.DeleteCustomerTimeline({
"id": "",
"messageId": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - messageId required
string
: The Customer Timeline message ID - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
Output schema unknown
GetCustomerTimeline
Retrieve a customer message with specified identifier string
rebilly.GetCustomerTimeline({
"id": "",
"messageId": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - messageId required
string
: The Customer Timeline message ID - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output CustomerTimeline
GetCustomerUpcomingInvoiceCollection
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.
rebilly.GetCustomerUpcomingInvoiceCollection({
"id": ""
}, context)
Input
- input
object
- expand
string
: Expand a response to get a full related object included inside - id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- expand
Output
- output
array
- items Invoice
GetDisputeCollection
Retrieve a list of disputes
rebilly.GetDisputeCollection({}, context)
Input
- input
object
- limit
integer
: The collection items limit - offset
integer
: The collection items offset - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- limit
Output
- output
array
- items Dispute
PostDispute
Create a dispute
rebilly.PostDispute({
"body": {
"currency": null,
"transactionId": "",
"postedTime": "",
"type": "",
"status": "",
"reasonCode": ""
}
}, context)
Input
- input
object
- body required Dispute
- Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output Dispute
GetDispute
Retrieve a dispute with specified identifier string
rebilly.GetDispute({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output Dispute
PutDispute
Create or update a Dispute with predefined identifier string
rebilly.PutDispute({
"body": {
"currency": null,
"transactionId": "",
"postedTime": "",
"type": "",
"status": "",
"reasonCode": ""
},
"id": ""
}, context)
Input
- input
object
- body required Dispute
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output Dispute
GetDisputeMatchedRuleCollection
Get matched rules for the dispute
rebilly.GetDisputeMatchedRuleCollection({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output
array
- items MatchedRule
GetFileCollection
Retrieve a list of files
rebilly.GetFileCollection({}, context)
Input
- input
object
- limit
integer
: The collection items limit - offset
integer
: The collection items offset - filter
string
: The collection items filter requires a special format. - q
string
: The partial search of the text fields. - expand
string
: Expand a response to get a full related object included inside - fields
string
: Limit the returned fields to the list specified, separated by comma. Note that id is always returned. - sort
array
: The collection items sort field and order (prefix with "-" for descending sort). - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- limit
Output
- output
array
- items File
PostFile
Additionally, a file can be sent with:
- multipart/form-data POST request: in this case all property names are the same as the JSON ones (
file
is an uploaded file) - file body request: the file body is sent as the request body, with the appropriate
Content-Type
. No additional properties can be set along the request data
The following file types only are allowed:
- jpg
- png
- gif
- mp3
If using a Publishable Api Key, only private files can be created. The files can later on be modified or used using a secret API key.
rebilly.PostFile({
"body": null
}, context)
Input
- input
object
- Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- Organization-Id
Output
- output File
DeleteFile
Delete the File with predefined identifier string
rebilly.DeleteFile({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
Output schema unknown
GetFile
Retrieve a File with specified identifier string
rebilly.GetFile({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output File
PutFile
Update the File with predefined ID. Note that file can be uploaded with POST only.
rebilly.PutFile({
"body": {},
"id": ""
}, context)
Input
- input
object
- body required File
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output File
GetFileDownload
Download a file
rebilly.GetFileDownload({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output
string
GetFileDownloadExtension
Download image in specific format. Images are converted server-side
rebilly.GetFileDownloadExtension({
"id": "",
"extension": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - extension required
string
(values: .png, .jpg, .gif): File extension which also indicates the desired file format - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output
string
GetInvoiceCollection
Retrieve a list of invoices
rebilly.GetInvoiceCollection({}, context)
Input
- input
object
- limit
integer
: The collection items limit - offset
integer
: The collection items offset - Accept
string
(values: application/json, text/csv): The response media type - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- limit
Output
- output
array
- items Invoice
PostInvoice
Create an invoice
rebilly.PostInvoice({
"body": {
"customerId": null,
"websiteId": null,
"currency": null
}
}, context)
Input
- input
object
- body required Invoice
- Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output Invoice
GetInvoice
Retrieve an invoice with specified identifier string
rebilly.GetInvoice({
"id": ""
}, context)
Input
- input
object
- Accept
string
(values: application/json, application/pdf): The response media type - id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- Accept
Output
- output Invoice
PutInvoice
Create or update an invoice with predefined identifier string
rebilly.PutInvoice({
"body": {
"customerId": null,
"websiteId": null,
"currency": null
},
"id": ""
}, context)
Input
- input
object
- body required Invoice
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output Invoice
PostInvoiceAbandonment
Abandon an invoice with specified identifier string
rebilly.PostInvoiceAbandonment({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output Invoice
PostInvoiceIssuance
Issue an invoice with specified identifier string. It must be in draft
status.
rebilly.PostInvoiceIssuance({
"body": {},
"id": ""
}, context)
Input
- input
object
- body required InvoiceIssue
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output Invoice
GetInvoiceItemCollection
Retrieve an invoice items with specified invoice identifier string
rebilly.GetInvoiceItemCollection({
"id": ""
}, context)
Input
- input
object
- limit
integer
: The collection items limit - offset
integer
: The collection items offset - id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- limit
Output
- output
array
- items InvoiceItem
PostInvoiceItem
Create an invoice item
rebilly.PostInvoiceItem({
"body": {
"type": "",
"unitPrice": 0
},
"id": ""
}, context)
Input
- input
object
- body required InvoiceItem
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output InvoiceItem
GetInvoiceMatchedRuleCollection
Get matched rules for the invoice
rebilly.GetInvoiceMatchedRuleCollection({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output
array
- items MatchedRule
PostInvoiceRecalculation
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.
rebilly.PostInvoiceRecalculation({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output Invoice
PostInvoiceReissuance
Reissue an invoice with specified identifier string. It must be issued (status must be unpaid
or past-due
).
rebilly.PostInvoiceReissuance({
"body": {},
"id": ""
}, context)
Input
- input
object
- body required InvoiceReissue
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output Invoice
GetInvoiceTimelineCollection
Retrieve a list of invoice timeline messages
rebilly.GetInvoiceTimelineCollection({
"id": ""
}, context)
Input
- input
object
- limit
integer
: The collection items limit - offset
integer
: The collection items offset - filter
string
: The collection items filter requires a special format. - id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- limit
Output
- output
array
- items InvoiceTimeline
PostInvoiceTimeline
Create an invoice Timeline comment
rebilly.PostInvoiceTimeline({
"body": {},
"id": ""
}, context)
Input
- input
object
- body required InvoiceTimeline
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output InvoiceTimeline
DeleteInvoiceTimeline
Delete an Invoice Timeline message with predefined identifier string
rebilly.DeleteInvoiceTimeline({
"id": "",
"messageId": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - messageId required
string
: The Invoice Timeline message ID - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
Output schema unknown
GetInvoiceTimeline
Retrieve a invoice message with specified identifier string
rebilly.GetInvoiceTimeline({
"id": "",
"messageId": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - messageId required
string
: The Invoice Timeline message ID - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output InvoiceTimeline
GetInvoiceTransactionAllocationCollection
Get the precise amounts from a transaction allocated as invoice payments
rebilly.GetInvoiceTransactionAllocationCollection({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output
array
PostInvoiceVoid
Void an invoice with specified identifier string
rebilly.PostInvoiceVoid({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output Invoice
GetKycDocumentCollection
Retrieve a list of KYC documents
rebilly.GetKycDocumentCollection({}, context)
Input
- input
object
- limit
integer
: The collection items limit - offset
integer
: The collection items offset - filter
string
: The collection items filter requires a special format. - sort
array
: The collection items sort field and order (prefix with "-" for descending sort). - Accept
string
(values: application/json): The response media type - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- limit
Output
- output
array
- items KycDocument
PostKycDocument
Create a KYC Document
rebilly.PostKycDocument({
"body": {
"fileId": null,
"customerId": null,
"documentType": "",
"status": ""
}
}, context)
Input
- input
object
- body required KycDocument
- Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output KycDocument
GetKycDocument
Retrieve a KYC document with specified identifier string.
rebilly.GetKycDocument({
"id": ""
}, context)
Input
- input
object
- Accept
string
(values: application/json): The response media type - id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- Accept
Output
- output KycDocument
PutKycDocument
Create or update a KYC document with predefined identifier string.
rebilly.PutKycDocument({
"body": {
"fileId": null,
"customerId": null,
"documentType": "",
"status": ""
},
"id": ""
}, context)
Input
- input
object
- body required KycDocument
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output KycDocument
PostKycDocumentAcceptance
Marks that status of the document as accepted
. Updates the review time and reviewer information. Intended to be used for manual overrides.
rebilly.PostKycDocumentAcceptance({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output KycDocument
PostKycDocumentRejection
Marks that status of the document as rejected
. Updates the review time and reviewer information. Intended to be used for manual overrides.
rebilly.PostKycDocumentRejection({
"body": {},
"id": ""
}, context)
Input
- input
object
- body required KycDocumentRejection
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output KycDocument
PostKycDocumentReview
Mark the KYC document as reviewed. Updates the review time and reviewer information.
rebilly.PostKycDocumentReview({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output KycDocument
GetPasswordTokenCollection
Retrieve a list of tokens
rebilly.GetPasswordTokenCollection({}, context)
Input
- input
object
- limit
integer
: The collection items limit - offset
integer
: The collection items offset - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- limit
Output
- output
array
- items ResetPasswordToken
PostPasswordToken
Create a Reset Password Token
rebilly.PostPasswordToken({
"body": {
"username": ""
}
}, context)
Input
- input
object
- body required ResetPasswordToken
- Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
Output
- output ResetPasswordToken
DeletePasswordToken
Delete a Reset Password Token with predefined identifier string
rebilly.DeletePasswordToken({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
Output schema unknown
GetPasswordToken
Retrieve a Reset Password Token with specified identifier string
rebilly.GetPasswordToken({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output ResetPasswordToken
GetPaymentCardCollection
Retrieve a list of Payments Cards
rebilly.GetPaymentCardCollection({}, context)
Input
- input
object
- limit
integer
: The collection items limit - offset
integer
: The collection items offset - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- limit
Output
- output
array
- items PaymentCard
PostPaymentCard
Create a Payment Card
rebilly.PostPaymentCard({
"body": null
}, context)
Input
- input
object
- Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- Organization-Id
Output
- output PaymentCard
GetPaymentCard
Retrieve a Payment Card with specified identifier string
rebilly.GetPaymentCard({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output PaymentCard
PatchPaymentCard
Update any of the payment card's values except for the pan
rebilly.PatchPaymentCard({
"id": ""
}, context)
Input
- input
object
- body
object
- billingAddress: Card's billing address
- address
string
: The contact street address - address2
string
: The contact street address (second line) - city
string
: The contact city - country
string
: The contact country ISO Alpha-2 code - emails ContactEmails
- firstName
string
: The contact first name - hash
string
: A hash that can be used to compare multiple contacts for identical attribute values - lastName
string
: The contact last name - organization
string
: The contact organization - phoneNumbers ContactPhoneNumbers
- postalCode
string
: The contact postal code - region
string
: The contact region (state)
- address
- customFields ResourceCustomFields
- cvv
string
: Card's cvv (card verification value). - expMonth
integer
: Card's expiry month - expYear
integer
: Card's expiry year - stickyGatewayAccountId: Sticky Gateway Account ID
- billingAddress: Card's billing address
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- body
Output
- output PaymentCard
PutPaymentCard
Create a payment card with predefined ID
rebilly.PutPaymentCard({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output PaymentCard
PostPaymentCardAuthorization
Authorize a Payment Card
Instead of using this endpoint a Payment Card will be authorized on first usage (new transaction or order).
rebilly.PostPaymentCardAuthorization({
"body": {
"websiteId": "",
"currency": null
},
"id": ""
}, context)
Input
- input
object
- body required
object
- amount
number
: Amount - currency required
- gatewayAccountId
string
: The Gateway account ID - redirectUrl
string
: Redirect URL - websiteId required
string
: The Website ID
- amount
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- body required
Output
- output PaymentCard
PostPaymentCardDeactivation
Deactivate a Payment Card
rebilly.PostPaymentCardDeactivation({
"id": ""
}, context)
Input
- input
object
- id required
string
: The resource identifier string - Organization-Id
string
: Organization identifier in scope of which need to perform request (if not specified, the default organization will be used)
- id required
Output
- output PaymentCard