{ "opencollection": "1.0.0", "info": { "name": "Admin Account / Address Payment Methods API", "version": "v3" }, "items": [ { "info": { "name": "Payment Methods", "type": "folder" }, "items": [ { "info": { "name": "List payment methods", "type": "http" }, "http": { "method": "GET", "url": "http://{defaultHost}/api/v3/admin/payment_methods", "headers": [ { "name": "x-spree-api-key", "value": "" }, { "name": "Authorization", "value": "" } ], "params": [ { "name": "expand", "value": "", "type": "query", "description": "Comma-separated associations to expand. Use dot notation for nested expand (max 4 levels)." }, { "name": "fields", "value": "", "type": "query", "description": "Comma-separated list of fields to include (e.g., name,type,active). id is always included." } ], "auth": { "type": "apikey", "key": "x-spree-api-key", "value": "{{x-spree-api-key}}", "placement": "header" } }, "docs": "Returns the store's configured payment methods. Use `source_required: true` to know which methods need a saved source.\n\n**Required scope:** `read_settings` (for API-key authentication)." }, { "info": { "name": "List available payment provider types", "type": "http" }, "http": { "method": "GET", "url": "http://{defaultHost}/api/v3/admin/payment_methods/types", "headers": [ { "name": "x-spree-api-key", "value": "" }, { "name": "Authorization", "value": "" } ], "auth": { "type": "apikey", "key": "x-spree-api-key", "value": "{{x-spree-api-key}}", "placement": "header" } }, "docs": "Returns the registered Spree::PaymentMethod subclasses that can be used to create new payment methods. Useful for populating a \"Provider\" dropdown in admin UIs.\n\n**Required scope:** `read_settings` (for API-key authentication)." }, { "info": { "name": "Show a payment method", "type": "http" }, "http": { "method": "GET", "url": "http://{defaultHost}/api/v3/admin/payment_methods/:id", "headers": [ { "name": "x-spree-api-key", "value": "" }, { "name": "Authorization", "value": "" } ], "params": [ { "name": "id", "value": "", "type": "path" }, { "name": "expand", "value": "", "type": "query", "description": "Comma-separated associations to expand. Use dot notation for nested expand (max 4 levels)." }, { "name": "fields", "value": "", "type": "query", "description": "Comma-separated list of fields to include (e.g., name,type,active). id is always included." } ], "auth": { "type": "apikey", "key": "x-spree-api-key", "value": "{{x-spree-api-key}}", "placement": "header" } }, "docs": "Returns a payment method by ID.\n\n**Required scope:** `read_settings` (for API-key authentication)." }, { "info": { "name": "Return a list of Payment Methods", "type": "http" }, "http": { "method": "GET", "url": "http://{defaultHost}/api/v2/platform/payment_methods", "params": [ { "name": "page", "value": "1", "type": "query" }, { "name": "per_page", "value": "50", "type": "query" }, { "name": "include", "value": "stores", "type": "query", "description": "Select which associated resources you would like to fetch, see: https://jsonapi.org/format/#fetching-includes" }, { "name": "filter[name]", "value": "Stripe", "type": "query" } ], "auth": { "type": "bearer", "token": "{{bearerToken}}" } }, "docs": "Returns a list of Payment Methods" }, { "info": { "name": "Create a Payment Method", "type": "http" }, "http": { "method": "POST", "url": "http://{defaultHost}/api/v2/platform/payment_methods", "params": [ { "name": "include", "value": "stores", "type": "query", "description": "Select which associated resources you would like to fetch, see: https://jsonapi.org/format/#fetching-includes" } ], "body": { "type": "json", "data": "{}" }, "auth": { "type": "bearer", "token": "{{bearerToken}}" } }, "docs": "Creates a Payment Method" }, { "info": { "name": "Return a Payment Method", "type": "http" }, "http": { "method": "GET", "url": "http://{defaultHost}/api/v2/platform/payment_methods/:id", "params": [ { "name": "id", "value": "", "type": "path" }, { "name": "include", "value": "stores", "type": "query", "description": "Select which associated resources you would like to fetch, see: https://jsonapi.org/format/#fetching-includes" } ], "auth": { "type": "bearer", "token": "{{bearerToken}}" } }, "docs": "Returns a Payment Method" }, { "info": { "name": "Update a Payment Method", "type": "http" }, "http": { "method": "PATCH", "url": "http://{defaultHost}/api/v2/platform/payment_methods/:id", "params": [ { "name": "id", "value": "", "type": "path" }, { "name": "include", "value": "stores", "type": "query", "description": "Select which associated resources you would like to fetch, see: https://jsonapi.org/format/#fetching-includes" } ], "body": { "type": "json", "data": "{}" }, "auth": { "type": "bearer", "token": "{{bearerToken}}" } }, "docs": "Updates a Payment Method" }, { "info": { "name": "Delete a Payment Method", "type": "http" }, "http": { "method": "DELETE", "url": "http://{defaultHost}/api/v2/platform/payment_methods/:id", "params": [ { "name": "id", "value": "", "type": "path" } ], "auth": { "type": "bearer", "token": "{{bearerToken}}" } }, "docs": "Deletes a Payment Method" } ] } ], "bundled": true }