All URIs are relative to http://localhost/v3
Method | HTTP request | Description |
---|---|---|
get_mccgroups | GET /mccgroups | Lists all MCC groups |
get_mccgroups_token | GET /mccgroups/{token} | Returns a specific MCC group |
post_mccgroups | POST /mccgroups | Creates an MCC group |
put_mccgroups_token | PUT /mccgroups/{token} | Updates an MCC group |
get_mccgroups(opts)
Lists all MCC groups
require 'time'
require 'marqeta'
api_instance = Marqeta::MccGroupsApi.new
opts = {
mcc: 'mcc_example', # String | MCC
count: 56, # Integer | Number of items to retrieve. Count can be between 1 - 10 items.
start_index: 56, # Integer | Indicates from what row to start returning data.
sort_by: 'sort_by_example' # String | Field by which to sort the returned items. Use any field in the model, or system fields lastModifiedTime or createdTime.
}
begin
# Lists all MCC groups
result = api_instance.get_mccgroups(opts)
p result
rescue Marqeta::ApiError => e
puts "Error when calling MccGroupsApi->get_mccgroups: #{e}"
end
This returns an Array which contains the response data, status code and headers.
<Array(, Integer, Hash)> get_mccgroups_with_http_info(opts)
begin
# Lists all MCC groups
data, status_code, headers = api_instance.get_mccgroups_with_http_info(opts)
p status_code # => 2xx
p headers # => { ... }
p data # => <MCCGroupListResponse>
rescue Marqeta::ApiError => e
puts "Error when calling MccGroupsApi->get_mccgroups_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
mcc | String | MCC | [optional] |
count | Integer | Number of items to retrieve. Count can be between 1 - 10 items. | [optional][default to 10] |
start_index | Integer | Indicates from what row to start returning data. | [optional][default to 0] |
sort_by | String | Field by which to sort the returned items. Use any field in the model, or system fields lastModifiedTime or createdTime. | [optional][default to '-lastModifiedTime'] |
No authorization required
- Content-Type: Not defined
- Accept: application/json
get_mccgroups_token(token)
Returns a specific MCC group
require 'time'
require 'marqeta'
api_instance = Marqeta::MccGroupsApi.new
token = 'token_example' # String | MCC group token
begin
# Returns a specific MCC group
result = api_instance.get_mccgroups_token(token)
p result
rescue Marqeta::ApiError => e
puts "Error when calling MccGroupsApi->get_mccgroups_token: #{e}"
end
This returns an Array which contains the response data, status code and headers.
<Array(, Integer, Hash)> get_mccgroups_token_with_http_info(token)
begin
# Returns a specific MCC group
data, status_code, headers = api_instance.get_mccgroups_token_with_http_info(token)
p status_code # => 2xx
p headers # => { ... }
p data # => <MccGroupModel>
rescue Marqeta::ApiError => e
puts "Error when calling MccGroupsApi->get_mccgroups_token_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
token | String | MCC group token |
No authorization required
- Content-Type: Not defined
- Accept: application/json
post_mccgroups(body)
Creates an MCC group
require 'time'
require 'marqeta'
api_instance = Marqeta::MccGroupsApi.new
body = Marqeta::MccGroupModel.new({name: 'name_example', mccs: [3.56]}) # MccGroupModel | MCC group
begin
# Creates an MCC group
result = api_instance.post_mccgroups(body)
p result
rescue Marqeta::ApiError => e
puts "Error when calling MccGroupsApi->post_mccgroups: #{e}"
end
This returns an Array which contains the response data, status code and headers.
<Array(, Integer, Hash)> post_mccgroups_with_http_info(body)
begin
# Creates an MCC group
data, status_code, headers = api_instance.post_mccgroups_with_http_info(body)
p status_code # => 2xx
p headers # => { ... }
p data # => <MccGroupModel>
rescue Marqeta::ApiError => e
puts "Error when calling MccGroupsApi->post_mccgroups_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
body | MccGroupModel | MCC group |
No authorization required
- Content-Type: Not defined
- Accept: application/json
put_mccgroups_token(token, body)
Updates an MCC group
require 'time'
require 'marqeta'
api_instance = Marqeta::MccGroupsApi.new
token = 'token_example' # String |
body = Marqeta::MccGroupUpdateModel.new # MccGroupUpdateModel | MCC group
begin
# Updates an MCC group
result = api_instance.put_mccgroups_token(token, body)
p result
rescue Marqeta::ApiError => e
puts "Error when calling MccGroupsApi->put_mccgroups_token: #{e}"
end
This returns an Array which contains the response data, status code and headers.
<Array(, Integer, Hash)> put_mccgroups_token_with_http_info(token, body)
begin
# Updates an MCC group
data, status_code, headers = api_instance.put_mccgroups_token_with_http_info(token, body)
p status_code # => 2xx
p headers # => { ... }
p data # => <MccGroupUpdateModel>
rescue Marqeta::ApiError => e
puts "Error when calling MccGroupsApi->put_mccgroups_token_with_http_info: #{e}"
end
Name | Type | Description | Notes |
---|---|---|---|
token | String | ||
body | MccGroupUpdateModel | MCC group |
No authorization required
- Content-Type: Not defined
- Accept: application/json