Class: Zazu::Resources::TransferDrafts
- Defined in:
- lib/zazu/resources/transfer_drafts.rb
Overview
API-initiated transfers. Creating a draft routes it into the
workspace's in-app approval flow — the API never executes a
transfer itself. A manager or legal representative approves in
the Zazu app; poll #get (status: requested → processing →
completed / failed) or subscribe to the transfer.executed
webhook to follow execution.
Constant Summary
Constants inherited from Base
Instance Attribute Summary
Attributes inherited from Base
Instance Method Summary collapse
-
#create(**attributes) ⇒ Object
POST /api/transfer_drafts.
-
#get(id) ⇒ Object
GET /api/transfer_drafts/:id.
Methods inherited from Base
Constructor Details
This class inherits a constructor from Zazu::Resources::Base
Instance Method Details
#create(**attributes) ⇒ Object
POST /api/transfer_drafts
Required: account_id, amount, and exactly one of beneficiary_id (external transfer) or destination_account_id (own-account move). Optional: external_account_id, currency_code, payment_reference, internal_notes.
18 19 20 |
# File 'lib/zazu/resources/transfer_drafts.rb', line 18 def create(**attributes) http_post("api/transfer_drafts", body: attributes) end |
#get(id) ⇒ Object
GET /api/transfer_drafts/:id
23 24 25 |
# File 'lib/zazu/resources/transfer_drafts.rb', line 23 def get(id) http_get(encode_path("api/transfer_drafts", id)) end |