Files
zeekay 189ce08e51 Regenerate against the document the deployment answers for
The projection these were generated from was a month old and predated the
compute migration, so every one of them described /v1/visor — which the API
serves at zero paths now. That is why a hand-written console client and a
generated one had drifted the same way at the same time.

No /v1/visor path survives here. The word still appears as a source-plane
value and inside gvisor and supervisor, which are not this rename.
2026-09-05 18:07:13 -07:00

196 lines
6.9 KiB
C++

/**
* Hanzo Cloud API
* The Hanzo Cloud API as a customer calls it: every operation under /v1/ except the operator's admin product, relay routes, legacy spellings and capabilities still reached by flag. Tagged by product: the first path segment after /v1/.
*
* The version of the OpenAPI document: v1
*
* NOTE: This class is auto generated by OpenAPI-Generator 7.14.0.
* https://openapi-generator.tech
* Do not edit the class manually.
*/
/*
* Receipt.h
*
*
*/
#ifndef HANZO_MODEL_Receipt_H_
#define HANZO_MODEL_Receipt_H_
#include <boost/optional.hpp>
#include "hanzo/ModelBase.h"
#include <cpprest/details/basic_types.h>
namespace hanzo {
namespace model {
class Receipt
: public ModelBase
{
public:
Receipt();
virtual ~Receipt();
/////////////////////////////////////////////
/// ModelBase overrides
void validate() override;
web::json::value toJson() const override;
bool fromJson(const web::json::value& json) override;
void toMultipart(std::shared_ptr<MultipartFormData> multipart, const utility::string_t& namePrefix) const override;
bool fromMultiPart(std::shared_ptr<MultipartFormData> multipart, const utility::string_t& namePrefix) override;
/////////////////////////////////////////////
/// Receipt members
/// <summary>
/// Amount is what actually moved, as an exact 18-decimal-place USD string. It is NOT the atomic-unit figure the client signed: the challenge quotes the asset&#39;s own units (USDC&#39;s 6 dp) and truncates to fit them, while the ledger moves this exact value.
/// </summary>
utility::string_t getAmount() const;
bool amountIsSet() const;
void unsetAmount();
void setAmount(const utility::string_t& value);
/// <summary>
/// From is the payer&#39;s EVM address: the account that signed the EIP-3009 authorization, recovered from the signature rather than taken on trust.
/// </summary>
utility::string_t getFrom() const;
bool fromIsSet() const;
void unsetFrom();
void setFrom(const utility::string_t& value);
/// <summary>
/// ID is the settle-once key: \&quot;x402_\&quot; + keccak(from|nonce) in hex. It is DERIVED, not minted, so a client that re-submits the same authorization addresses the same settlement and is served again for free rather than charged twice. It is also the id GET /v1/x402/settlements/:id takes.
/// </summary>
utility::string_t getId() const;
bool idIsSet() const;
void unsetId();
void setId(const utility::string_t& value);
/// <summary>
/// Network is the CAIP-2 identifier the payment was settled under, e.g. \&quot;eip155:36963\&quot;. Its eip155 reference is the chain id in the EIP-712 domain the payer signed, so it is not a label — changing it invalidates the signature.
/// </summary>
utility::string_t getNetwork() const;
bool networkIsSet() const;
void unsetNetwork();
void setNetwork(const utility::string_t& value);
/// <summary>
/// Nonce is the client-chosen nonce from the authorization, hex — up to 32 bytes, left-padded to the contract&#39;s bytes32. It is the replay anchor: the token contract refuses a second on-chain transfer for one (from, nonce), and this rail refuses a second settlement for the same pair, so a ledger settlement inherits the identical guarantee.
/// </summary>
utility::string_t getNonce() const;
bool nonceIsSet() const;
void unsetNonce();
void setNonce(const utility::string_t& value);
/// <summary>
/// Payee is the recipient&#39;s EVM address — the &#x60;payTo&#x60; the challenge advertised and the authorization named. A payment to any other address never settles.
/// </summary>
utility::string_t getPayee() const;
bool payeeIsSet() const;
void unsetPayee();
void setPayee(const utility::string_t& value);
/// <summary>
/// PayeeOrg is the tenant that owns the recipient wallet, resolved at settlement. It is who got PAID, as Payer is who paid.
/// </summary>
utility::string_t getPayeeOrg() const;
bool payeeOrgIsSet() const;
void unsetPayeeOrg();
void setPayeeOrg(const utility::string_t& value);
/// <summary>
/// Payer is the payer ORG — the tenant whose ledger was debited — and not an address. It is the org the request was authenticated as, so it answers who is billed, which the payer address alone cannot.
/// </summary>
utility::string_t getPayer() const;
bool payerIsSet() const;
void unsetPayer();
void setPayer(const utility::string_t& value);
/// <summary>
/// Resource is what was paid for, in the same spelling the price table and the challenge used: the request path for a priced route, \&quot;tool:&lt;id&gt;\&quot; for a priced tool.
/// </summary>
utility::string_t getResource() const;
bool resourceIsSet() const;
void unsetResource();
void setResource(const utility::string_t& value);
/// <summary>
/// SettledAt is when this settlement was CLAIMED, in unix seconds — the moment the authorization was accepted, which is also the moment the time window it carried stopped applying. A settlement finished later by reconciliation keeps this instant.
/// </summary>
int64_t getSettledAt() const;
bool settledAtIsSet() const;
void unsetSettledAt();
void setSettledAt(int64_t value);
/// <summary>
/// SettledVia is which rail moved the money: \&quot;ledger\&quot;, the live default, or \&quot;chain\&quot; when the authorization is broadcast. Those two values and no others.
/// </summary>
utility::string_t getSettledVia() const;
bool settledViaIsSet() const;
void unsetSettledVia();
void setSettledVia(const utility::string_t& value);
/// <summary>
/// TxHash is the chain transaction hash, present only for a \&quot;chain\&quot; settlement. Empty on a ledger settlement — that is the normal case today, and it means the money moved without a chain, not that it failed. The wire&#39;s PAYMENT-RESPONSE &#x60;transaction&#x60; falls back to ID when this is empty.
/// </summary>
utility::string_t getTxHash() const;
bool txHashIsSet() const;
void unsetTxHash();
void setTxHash(const utility::string_t& value);
protected:
utility::string_t m_Amount;
bool m_AmountIsSet;
utility::string_t m_From;
bool m_FromIsSet;
utility::string_t m_Id;
bool m_IdIsSet;
utility::string_t m_Network;
bool m_NetworkIsSet;
utility::string_t m_Nonce;
bool m_NonceIsSet;
utility::string_t m_Payee;
bool m_PayeeIsSet;
utility::string_t m_PayeeOrg;
bool m_PayeeOrgIsSet;
utility::string_t m_Payer;
bool m_PayerIsSet;
utility::string_t m_Resource;
bool m_ResourceIsSet;
int64_t m_SettledAt;
bool m_SettledAtIsSet;
utility::string_t m_SettledVia;
bool m_SettledViaIsSet;
utility::string_t m_TxHash;
bool m_TxHashIsSet;
};
}
}
#endif /* HANZO_MODEL_Receipt_H_ */