Class: MetronomeSDK::Resources::V1
- Inherits:
-
Object
- Object
- MetronomeSDK::Resources::V1
- Defined in:
- lib/metronome_sdk/resources/v1.rb,
lib/metronome_sdk/resources/v1/plans.rb,
lib/metronome_sdk/resources/v1/usage.rb,
lib/metronome_sdk/resources/v1/alerts.rb,
lib/metronome_sdk/resources/v1/invoices.rb,
lib/metronome_sdk/resources/v1/packages.rb,
lib/metronome_sdk/resources/v1/payments.rb,
lib/metronome_sdk/resources/v1/services.rb,
lib/metronome_sdk/resources/v1/settings.rb,
lib/metronome_sdk/resources/v1/contracts.rb,
lib/metronome_sdk/resources/v1/customers.rb,
lib/metronome_sdk/resources/v1/audit_logs.rb,
lib/metronome_sdk/resources/v1/dashboards.rb,
lib/metronome_sdk/resources/v1/credit_grants.rb,
lib/metronome_sdk/resources/v1/custom_fields.rb,
lib/metronome_sdk/resources/v1/pricing_units.rb,
lib/metronome_sdk/resources/v1/customers/plans.rb,
lib/metronome_sdk/resources/v1/billable_metrics.rb,
lib/metronome_sdk/resources/v1/customers/alerts.rb,
lib/metronome_sdk/resources/v1/customers/commits.rb,
lib/metronome_sdk/resources/v1/customers/credits.rb,
lib/metronome_sdk/resources/v1/contracts/products.rb,
lib/metronome_sdk/resources/v1/customers/invoices.rb,
lib/metronome_sdk/resources/v1/contracts/rate_cards.rb,
lib/metronome_sdk/resources/v1/customers/billing_config.rb,
lib/metronome_sdk/resources/v1/contracts/named_schedules.rb,
lib/metronome_sdk/resources/v1/customers/named_schedules.rb,
lib/metronome_sdk/resources/v1/contracts/rate_cards/rates.rb,
lib/metronome_sdk/resources/v1/settings/billing_providers.rb,
lib/metronome_sdk/resources/v1/contracts/rate_cards/product_orders.rb,
lib/metronome_sdk/resources/v1/contracts/rate_cards/named_schedules.rb
Defined Under Namespace
Classes: Alerts, AuditLogs, BillableMetrics, Contracts, CreditGrants, CustomFields, Customers, Dashboards, Invoices, Packages, Payments, Plans, PricingUnits, Services, Settings, Usage
Instance Attribute Summary collapse
-
#alerts ⇒ MetronomeSDK::Resources::V1::Alerts
readonly
[Alerts](docs.metronome.com/connecting-metronome/alerts/) monitor customer spending, balances, and other billing factors.
-
#audit_logs ⇒ MetronomeSDK::Resources::V1::AuditLogs
readonly
[Security](docs.metronome.com/developer-resources/security/) endpoints allow you to retrieve security-related data.
-
#billable_metrics ⇒ MetronomeSDK::Resources::V1::BillableMetrics
readonly
[Billable metrics](docs.metronome.com/understanding-metronome/how-metronome-works#billable-metrics) in Metronome represent the various consumption components that Metronome meters and aggregates.
- #contracts ⇒ MetronomeSDK::Resources::V1::Contracts readonly
-
#credit_grants ⇒ MetronomeSDK::Resources::V1::CreditGrants
readonly
[Credit grants](docs.metronome.com/invoicing/how-billing-works/manage-credits/) adjust a customer balance for prepayments, reimbursements, promotions, and so on.
-
#custom_fields ⇒ MetronomeSDK::Resources::V1::CustomFields
readonly
[Custom fields](docs.metronome.com/integrations/custom-fields/) enable adding additional data to Metronome entities.
- #customers ⇒ MetronomeSDK::Resources::V1::Customers readonly
-
#dashboards ⇒ MetronomeSDK::Resources::V1::Dashboards
readonly
[Customers](docs.metronome.com/provisioning/create-customers/) in Metronome represent your users for all billing and reporting.
-
#invoices ⇒ MetronomeSDK::Resources::V1::Invoices
readonly
[Invoices](docs.metronome.com/invoicing/) reflect how much a customer spent during a period, which is the basis for billing.
- #packages ⇒ MetronomeSDK::Resources::V1::Packages readonly
- #payments ⇒ MetronomeSDK::Resources::V1::Payments readonly
-
#plans ⇒ MetronomeSDK::Resources::V1::Plans
readonly
[Plans](docs.metronome.com/pricing-and-packaging/create-plans/) determine the base pricing for a customer.
-
#pricing_units ⇒ MetronomeSDK::Resources::V1::PricingUnits
readonly
Use these endpoints to configure a billing API key, a webhook secret, or invoice finalization behavior.
-
#services ⇒ MetronomeSDK::Resources::V1::Services
readonly
[Security](docs.metronome.com/developer-resources/security/) endpoints allow you to retrieve security-related data.
-
#settings ⇒ MetronomeSDK::Resources::V1::Settings
readonly
Use these endpoints to configure a billing API key, a webhook secret, or invoice finalization behavior.
-
#usage ⇒ MetronomeSDK::Resources::V1::Usage
readonly
[Usage events](docs.metronome.com/connecting-metronome/send-usage-data/) are the basis for billable metrics.
Instance Method Summary collapse
-
#initialize(client:) ⇒ V1
constructor
private
A new instance of V1.
Constructor Details
#initialize(client:) ⇒ V1
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of V1.
94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 |
# File 'lib/metronome_sdk/resources/v1.rb', line 94 def initialize(client:) @client = client @alerts = MetronomeSDK::Resources::V1::Alerts.new(client: client) @plans = MetronomeSDK::Resources::V1::Plans.new(client: client) @credit_grants = MetronomeSDK::Resources::V1::CreditGrants.new(client: client) @pricing_units = MetronomeSDK::Resources::V1::PricingUnits.new(client: client) @customers = MetronomeSDK::Resources::V1::Customers.new(client: client) @dashboards = MetronomeSDK::Resources::V1::Dashboards.new(client: client) @usage = MetronomeSDK::Resources::V1::Usage.new(client: client) @audit_logs = MetronomeSDK::Resources::V1::AuditLogs.new(client: client) @custom_fields = MetronomeSDK::Resources::V1::CustomFields.new(client: client) @billable_metrics = MetronomeSDK::Resources::V1::BillableMetrics.new(client: client) @services = MetronomeSDK::Resources::V1::Services.new(client: client) @invoices = MetronomeSDK::Resources::V1::Invoices.new(client: client) @contracts = MetronomeSDK::Resources::V1::Contracts.new(client: client) @packages = MetronomeSDK::Resources::V1::Packages.new(client: client) @payments = MetronomeSDK::Resources::V1::Payments.new(client: client) @settings = MetronomeSDK::Resources::V1::Settings.new(client: client) end |
Instance Attribute Details
#alerts ⇒ MetronomeSDK::Resources::V1::Alerts (readonly)
[Alerts](docs.metronome.com/connecting-metronome/alerts/) monitor customer spending, balances, and other billing factors. Use these endpoints to create, retrieve, and archive customer alerts. To view sample alert payloads by alert type, navigate [here.](docs.metronome.com/manage-product-access/create-manage-alerts/#webhook-notifications)
12 13 14 |
# File 'lib/metronome_sdk/resources/v1.rb', line 12 def alerts @alerts end |
#audit_logs ⇒ MetronomeSDK::Resources::V1::AuditLogs (readonly)
[Security](docs.metronome.com/developer-resources/security/) endpoints allow you to retrieve security-related data.
51 52 53 |
# File 'lib/metronome_sdk/resources/v1.rb', line 51 def audit_logs @audit_logs end |
#billable_metrics ⇒ MetronomeSDK::Resources::V1::BillableMetrics (readonly)
[Billable metrics](docs.metronome.com/understanding-metronome/how-metronome-works#billable-metrics) in Metronome represent the various consumption components that Metronome meters and aggregates.
63 64 65 |
# File 'lib/metronome_sdk/resources/v1.rb', line 63 def billable_metrics @billable_metrics end |
#contracts ⇒ MetronomeSDK::Resources::V1::Contracts (readonly)
78 79 80 |
# File 'lib/metronome_sdk/resources/v1.rb', line 78 def contracts @contracts end |
#credit_grants ⇒ MetronomeSDK::Resources::V1::CreditGrants (readonly)
[Credit grants](docs.metronome.com/invoicing/how-billing-works/manage-credits/) adjust a customer balance for prepayments, reimbursements, promotions, and so on. Use these endpoints to create, retrieve, update, and delete credit grants.
25 26 27 |
# File 'lib/metronome_sdk/resources/v1.rb', line 25 def credit_grants @credit_grants end |
#custom_fields ⇒ MetronomeSDK::Resources::V1::CustomFields (readonly)
[Custom fields](docs.metronome.com/integrations/custom-fields/) enable adding additional data to Metronome entities. Use these endpoints to create, retrieve, update, and delete custom fields.
57 58 59 |
# File 'lib/metronome_sdk/resources/v1.rb', line 57 def custom_fields @custom_fields end |
#customers ⇒ MetronomeSDK::Resources::V1::Customers (readonly)
33 34 35 |
# File 'lib/metronome_sdk/resources/v1.rb', line 33 def customers @customers end |
#dashboards ⇒ MetronomeSDK::Resources::V1::Dashboards (readonly)
[Customers](docs.metronome.com/provisioning/create-customers/) in Metronome represent your users for all billing and reporting. Use these endpoints to create, retrieve, update, and archive customers and their billing configuration.
40 41 42 |
# File 'lib/metronome_sdk/resources/v1.rb', line 40 def dashboards @dashboards end |
#invoices ⇒ MetronomeSDK::Resources::V1::Invoices (readonly)
[Invoices](docs.metronome.com/invoicing/) reflect how much a customer spent during a period, which is the basis for billing. Metronome automatically generates invoices based upon your pricing, packaging, and usage events. Use these endpoints to retrieve invoices.
75 76 77 |
# File 'lib/metronome_sdk/resources/v1.rb', line 75 def invoices @invoices end |
#packages ⇒ MetronomeSDK::Resources::V1::Packages (readonly)
81 82 83 |
# File 'lib/metronome_sdk/resources/v1.rb', line 81 def packages @packages end |
#payments ⇒ MetronomeSDK::Resources::V1::Payments (readonly)
84 85 86 |
# File 'lib/metronome_sdk/resources/v1.rb', line 84 def payments @payments end |
#plans ⇒ MetronomeSDK::Resources::V1::Plans (readonly)
[Plans](docs.metronome.com/pricing-and-packaging/create-plans/) determine the base pricing for a customer. Use these endpoints to add a plan to a customer, end a customer plan, retrieve plans, and retrieve plan details. Create plans in the [Metronome app](app.metronome.com/plans).
19 20 21 |
# File 'lib/metronome_sdk/resources/v1.rb', line 19 def plans @plans end |
#pricing_units ⇒ MetronomeSDK::Resources::V1::PricingUnits (readonly)
Use these endpoints to configure a billing API key, a webhook secret, or invoice finalization behavior.
30 31 32 |
# File 'lib/metronome_sdk/resources/v1.rb', line 30 def pricing_units @pricing_units end |
#services ⇒ MetronomeSDK::Resources::V1::Services (readonly)
[Security](docs.metronome.com/developer-resources/security/) endpoints allow you to retrieve security-related data.
68 69 70 |
# File 'lib/metronome_sdk/resources/v1.rb', line 68 def services @services end |
#settings ⇒ MetronomeSDK::Resources::V1::Settings (readonly)
Use these endpoints to configure a billing API key, a webhook secret, or invoice finalization behavior.
89 90 91 |
# File 'lib/metronome_sdk/resources/v1.rb', line 89 def settings @settings end |
#usage ⇒ MetronomeSDK::Resources::V1::Usage (readonly)
[Usage events](docs.metronome.com/connecting-metronome/send-usage-data/) are the basis for billable metrics. Use these endpoints to send usage events to Metronome and retrieve aggregated event data.
46 47 48 |
# File 'lib/metronome_sdk/resources/v1.rb', line 46 def usage @usage end |