Devdraft - the Ruby gem for the Devdraft AI Payment & Business Management API
A comprehensive payment processing and business management API that enables seamless integration of cryptocurrency and traditional payment methods.
This SDK is automatically generated by the OpenAPI Generator project:
- API version: 1.0.0
- Package version: 1.0.0
- Generator version: 7.17.0
- Build package: org.openapitools.codegen.languages.RubyClientCodegen
To build the Ruby code into a gem:
gem build devdraft.gemspecThen either install the gem locally:
gem install ./devdraft-1.0.0.gem(for development, run gem install --dev ./devdraft-1.0.0.gem to install the development dependencies)
or publish the gem to a gem hosting service, e.g. RubyGems.
Finally add this to the Gemfile:
gem 'devdraft', '~> 1.0.0'
If the Ruby gem is hosted at a git repository: https://github.com/GIT_USER_ID/GIT_REPO_ID, then add the following in the Gemfile:
gem 'devdraft', :git => 'https://github.com/GIT_USER_ID/GIT_REPO_ID.git'
Include the Ruby code directly using -I as follows:
ruby -Ilib script.rbPlease follow the installation procedure and then run the following code:
# Load the gem
require 'devdraft'
# Setup authorization
Devdraft.configure do |config|
# Configure API key authorization: x-client-secret
config.api_key['x-client-secret'] = '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['x-client-secret'] = 'Bearer'
# Configure API key authorization: x-client-key
config.api_key['x-client-key'] = '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['x-client-key'] = 'Bearer'
end
api_instance = Devdraft::APIHealthApi.new
begin
#Authenticated health check endpoint
result = api_instance.health_controller_check_v0
p result
rescue Devdraft::ApiError => e
puts "Exception when calling APIHealthApi->health_controller_check_v0: #{e}"
endThis SDK includes comprehensive examples demonstrating common use cases. Each example includes simple usage, advanced workflows, and error handling scenarios.
# Ruby quick start example
# See examples directory for full implementationEach example file contains:
- Simple Examples: Basic usage with minimal code
- Advanced Examples: Complex workflows and best practices
- Error Scenarios: How to handle errors and edge cases
For detailed examples, see the examples directory.
All URIs are relative to https://api.devdraft.ai
| Class | Method | HTTP request | Description |
|---|---|---|---|
| Devdraft::APIHealthApi | health_controller_check_v0 | GET /api/v0/health | Authenticated health check endpoint |
| Devdraft::APIHealthApi | health_controller_public_health_check_v0 | GET /api/v0/health/public | Public health check endpoint |
| Devdraft::AppBalancesApi | balance_controller_get_all_balances | GET /api/v0/balance | Get all stablecoin balances for an app |
| Devdraft::AppBalancesApi | balance_controller_get_eurc_balance | GET /api/v0/balance/eurc | Get EURC balance for an app |
| Devdraft::AppBalancesApi | balance_controller_get_usdc_balance | GET /api/v0/balance/usdc | Get USDC balance for an app |
| Devdraft::CustomersApi | customer_controller_create | POST /api/v0/customers | Create a new customer |
| Devdraft::CustomersApi | customer_controller_find_all | GET /api/v0/customers | Get all customers with filters |
| Devdraft::CustomersApi | customer_controller_find_one | GET /api/v0/customers/{id} | Get a customer by ID |
| Devdraft::CustomersApi | customer_controller_update | PATCH /api/v0/customers/{id} | Update a customer |
| Devdraft::ExchangeRatesApi | exchange_rate_controller_get_eurto_usd_rate | GET /api/v0/exchange-rate/eur-to-usd | Get EUR to USD exchange rate |
| Devdraft::ExchangeRatesApi | exchange_rate_controller_get_exchange_rate | GET /api/v0/exchange-rate | Get exchange rate between specified currencies |
| Devdraft::ExchangeRatesApi | exchange_rate_controller_get_usdto_eur_rate | GET /api/v0/exchange-rate/usd-to-eur | Get USD to EUR exchange rate |
| Devdraft::InvoicesApi | invoice_controller_create | POST /api/v0/invoices | Create a new invoice |
| Devdraft::InvoicesApi | invoice_controller_find_all | GET /api/v0/invoices | Get all invoices |
| Devdraft::InvoicesApi | invoice_controller_find_one | GET /api/v0/invoices/{id} | Get an invoice by ID |
| Devdraft::InvoicesApi | invoice_controller_update | PUT /api/v0/invoices/{id} | Update an invoice |
| Devdraft::LiquidationAddressesApi | liquidation_address_controller_create_liquidation_address | POST /api/v0/customers/{customerId}/liquidation_addresses | Create a new liquidation address for a customer |
| Devdraft::LiquidationAddressesApi | liquidation_address_controller_get_liquidation_address | GET /api/v0/customers/{customerId}/liquidation_addresses/{liquidationAddressId} | Get a specific liquidation address |
| Devdraft::LiquidationAddressesApi | liquidation_address_controller_get_liquidation_addresses | GET /api/v0/customers/{customerId}/liquidation_addresses | Get all liquidation addresses for a customer |
| Devdraft::PaymentIntentsApi | payment_intent_controller_create_bank_payment_intent | POST /api/v0/payment-intents/bank | Create a bank payment intent |
| Devdraft::PaymentIntentsApi | payment_intent_controller_create_stable_payment_intent | POST /api/v0/payment-intents/stablecoin | Create a stable payment intent |
| Devdraft::PaymentLinksApi | payment_links_controller_create | POST /api/v0/payment-links | Create a new payment link |
| Devdraft::PaymentLinksApi | payment_links_controller_find_all | GET /api/v0/payment-links | Get all payment links |
| Devdraft::PaymentLinksApi | payment_links_controller_find_one | GET /api/v0/payment-links/{id} | Get a payment link by ID |
| Devdraft::PaymentLinksApi | payment_links_controller_update | PUT /api/v0/payment-links/{id} | Update a payment link |
| Devdraft::ProductsApi | product_controller_create | POST /api/v0/products | Create a new product |
| Devdraft::ProductsApi | product_controller_find_all | GET /api/v0/products | Get all products |
| Devdraft::ProductsApi | product_controller_find_one | GET /api/v0/products/{id} | Get a product by ID |
| Devdraft::ProductsApi | product_controller_remove | DELETE /api/v0/products/{id} | Delete a product |
| Devdraft::ProductsApi | product_controller_update | PUT /api/v0/products/{id} | Update a product |
| Devdraft::ProductsApi | product_controller_upload_image | POST /api/v0/products/{id}/images | Upload images for a product |
| Devdraft::TaxesApi | tax_controller_create | POST /api/v0/taxes | Create a new tax |
| Devdraft::TaxesApi | tax_controller_delete_without_id | DELETE /api/v0/taxes | Tax ID required for deletion |
| Devdraft::TaxesApi | tax_controller_find_all | GET /api/v0/taxes | Get all taxes with filters |
| Devdraft::TaxesApi | tax_controller_find_one | GET /api/v0/taxes/{id} | Get a tax by ID |
| Devdraft::TaxesApi | tax_controller_remove | DELETE /api/v0/taxes/{id} | Delete a tax |
| Devdraft::TaxesApi | tax_controller_update | PUT /api/v0/taxes/{id} | Update a tax |
| Devdraft::TaxesApi | tax_controller_update_without_id | PUT /api/v0/taxes | Tax ID required for updates |
| Devdraft::TestPaymentsApi | test_payment_controller_create_payment_v0 | POST /api/v0/test-payment | Process a test payment |
| Devdraft::TestPaymentsApi | test_payment_controller_get_payment_v0 | GET /api/v0/test-payment/{id} | Get payment details by ID |
| Devdraft::TestPaymentsApi | test_payment_controller_refund_payment_v0 | POST /api/v0/test-payment/{id}/refund | Refund a payment |
| Devdraft::TransfersApi | transfer_controller_create_direct_bank_transfer | POST /api/v0/transfers/direct-bank | Create a direct bank transfer |
| Devdraft::TransfersApi | transfer_controller_create_direct_wallet_transfer | POST /api/v0/transfers/direct-wallet | Create a direct wallet transfer |
| Devdraft::TransfersApi | transfer_controller_create_external_bank_transfer | POST /api/v0/transfers/external-bank-transfer | Create an external bank transfer |
| Devdraft::TransfersApi | transfer_controller_create_external_stablecoin_transfer | POST /api/v0/transfers/external-stablecoin-transfer | Create an external stablecoin transfer |
| Devdraft::TransfersApi | transfer_controller_create_stablecoin_conversion | POST /api/v0/transfers/stablecoin-conversion | Create a stablecoin conversion |
| Devdraft::WalletsApi | wallet_controller_get_wallets | GET /api/v0/wallets | Get wallets for an app |
| Devdraft::WebhooksApi | webhook_controller_create | POST /api/v0/webhooks | Create a new webhook |
| Devdraft::WebhooksApi | webhook_controller_find_all | GET /api/v0/webhooks | Get all webhooks |
| Devdraft::WebhooksApi | webhook_controller_find_one | GET /api/v0/webhooks/{id} | Get a webhook by id |
| Devdraft::WebhooksApi | webhook_controller_remove | DELETE /api/v0/webhooks/{id} | Delete a webhook |
| Devdraft::WebhooksApi | webhook_controller_update | PATCH /api/v0/webhooks/{id} | Update a webhook |
- Devdraft::AggregatedBalanceResponse
- Devdraft::AllBalancesResponse
- Devdraft::BridgeFiatPaymentRail
- Devdraft::BridgePaymentRail
- Devdraft::CreateBankPaymentIntentDto
- Devdraft::CreateCustomerDto
- Devdraft::CreateDirectBankTransferDto
- Devdraft::CreateDirectWalletTransferDto
- Devdraft::CreateExternalBankTransferDto
- Devdraft::CreateExternalStablecoinTransferDto
- Devdraft::CreateInvoiceDto
- Devdraft::CreateLiquidationAddressDto
- Devdraft::CreatePaymentLinkDto
- Devdraft::CreateStablePaymentIntentDto
- Devdraft::CreateStablecoinConversionDto
- Devdraft::CreateTaxDto
- Devdraft::CreateWebhookDto
- Devdraft::CustomerStatus
- Devdraft::CustomerType
- Devdraft::DestinationCurrency
- Devdraft::ExchangeRateResponseDto
- Devdraft::FiatCurrency
- Devdraft::HealthResponseDto
- Devdraft::InvoiceProductDto
- Devdraft::LiquidationAddressResponseDto
- Devdraft::PaymentLinkProductDto
- Devdraft::PaymentRequestDto
- Devdraft::PaymentResponseDto
- Devdraft::PublicHealthResponseDto
- Devdraft::RefundResponseDto
- Devdraft::StableCoinCurrency
- Devdraft::TaxControllerCreate201Response
- Devdraft::TaxControllerDeleteWithoutId400Response
- Devdraft::TaxControllerUpdateWithoutId400Response
- Devdraft::UpdateCustomerDto
- Devdraft::UpdateTaxDto
- Devdraft::UpdateWebhookDto
- Devdraft::WebhookResponseDto
Authentication schemes defined for the API:
- Type: API key
- API key parameter name: x-client-key
- Location: HTTP header
- Type: API key
- API key parameter name: x-client-secret
- Location: HTTP header
- Type: API key
- API key parameter name: idempotency-key
- Location: HTTP header