All URIs are relative to https://api-sandbox.rebilly.com/organizations/{organizationId}
| Method | HTTP request | Description |
|---|---|---|
| delete_shipping_rate | DELETE /shipping-rates/{id} | Delete a shipping rate |
| get_shipping_rate | GET /shipping-rates/{id} | Retrieve a shipping rate |
| get_shipping_rate_collection | GET /shipping-rates | Retrieve a list of shipping rates |
| post_shipping_rate | POST /shipping-rates | Create a shipping rate |
| put_shipping_rate | PUT /shipping-rates/{id} | Create a shipping rate with predefined ID |
delete_shipping_rate(id, opts)
Delete a shipping rate
Delete a shipping rate 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::ShippingRatesApi.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
#Delete a shipping rate
api_instance.delete_shipping_rate(id, opts)
rescue RebillySdk::ApiError => e
puts "Exception when calling ShippingRatesApi->delete_shipping_rate: #{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] |
nil (empty response body)
- Content-Type: Not defined
- Accept: application/json
ShippingRate get_shipping_rate(id, opts)
Retrieve a shipping rate
Retrieve a shipping rate 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::ShippingRatesApi.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
#Retrieve a shipping rate
result = api_instance.get_shipping_rate(id, opts)
p result
rescue RebillySdk::ApiError => e
puts "Exception when calling ShippingRatesApi->get_shipping_rate: #{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
Array<ShippingRate> get_shipping_rate_collection(opts)
Retrieve a list of shipping rates
Retrieve a list of shipping rates.
# 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::ShippingRatesApi.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.
limit: 56, # Integer | The collection items limit.
offset: 56, # Integer | The collection items offset.
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).
q: 'q_example' # String | The partial search of the text fields.
}
begin
#Retrieve a list of shipping rates
result = api_instance.get_shipping_rate_collection(opts)
p result
rescue RebillySdk::ApiError => e
puts "Exception when calling ShippingRatesApi->get_shipping_rate_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] |
| limit | Integer | The collection items limit. | [optional] |
| offset | Integer | The collection items offset. | [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] |
| q | String | The partial search of the text fields. | [optional] |
- Content-Type: Not defined
- Accept: application/json
ShippingRate post_shipping_rate(body, opts)
Create a shipping rate
Create a shipping rate.
# 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::ShippingRatesApi.new
body = RebillySdk::ShippingRate.new # ShippingRate | Shipping rate 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 a shipping rate
result = api_instance.post_shipping_rate(body, opts)
p result
rescue RebillySdk::ApiError => e
puts "Exception when calling ShippingRatesApi->post_shipping_rate: #{e}"
end| Name | Type | Description | Notes |
|---|---|---|---|
| body | ShippingRate | Shipping rate 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
ShippingRate put_shipping_rate(bodyid, opts)
Create a shipping rate with predefined ID
Create a shipping rate 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::ShippingRatesApi.new
body = RebillySdk::ShippingRate.new # ShippingRate | Shipping rate 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 a shipping rate with predefined ID
result = api_instance.put_shipping_rate(bodyid, opts)
p result
rescue RebillySdk::ApiError => e
puts "Exception when calling ShippingRatesApi->put_shipping_rate: #{e}"
end| Name | Type | Description | Notes |
|---|---|---|---|
| body | ShippingRate | Shipping rate 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