mirror of
https://github.com/hanzo-cpp/sdk.git
synced 2026-11-20 19:55:32 +00:00
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.
119 lines
3.5 KiB
C++
119 lines
3.5 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.
|
|
*/
|
|
|
|
/*
|
|
* Charged.h
|
|
*
|
|
*
|
|
*/
|
|
|
|
#ifndef HANZO_MODEL_Charged_H_
|
|
#define HANZO_MODEL_Charged_H_
|
|
|
|
#include <boost/optional.hpp>
|
|
|
|
#include "hanzo/ModelBase.h"
|
|
|
|
#include <cpprest/details/basic_types.h>
|
|
|
|
namespace hanzo {
|
|
namespace model {
|
|
|
|
|
|
|
|
class Charged
|
|
: public ModelBase
|
|
{
|
|
public:
|
|
Charged();
|
|
virtual ~Charged();
|
|
|
|
/////////////////////////////////////////////
|
|
/// 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;
|
|
|
|
|
|
/////////////////////////////////////////////
|
|
/// Charged members
|
|
|
|
|
|
/// <summary>
|
|
/// BalanceCents is the subject's balance AFTER the charge settled, in cents, so a caller does not have to re-read to show the new number.
|
|
/// </summary>
|
|
int64_t getBalanceCents() const;
|
|
bool balanceCentsIsSet() const;
|
|
void unsetBalanceCents();
|
|
void setBalanceCents(int64_t value);
|
|
|
|
/// <summary>
|
|
/// ProcessorRef is the payment processor's own reference. It is the only field that proves money moved at the GATEWAY rather than merely in our ledger, which is why it is answered and not only logged. Absent where the processor returned none.
|
|
/// </summary>
|
|
utility::string_t getProcessorRef() const;
|
|
bool processorRefIsSet() const;
|
|
void unsetProcessorRef();
|
|
void setProcessorRef(const utility::string_t& value);
|
|
|
|
/// <summary>
|
|
/// Status is how the charge ended. Read it rather than inferring success from the HTTP status: the call succeeded whenever this field is present, and what the PROCESSOR did is what this says.
|
|
/// </summary>
|
|
utility::string_t getStatus() const;
|
|
bool statusIsSet() const;
|
|
void unsetStatus();
|
|
void setStatus(const utility::string_t& value);
|
|
|
|
/// <summary>
|
|
/// Test states which bucket was credited — sandbox money or real money — so no reader has to guess whether a receipt is real. Sandbox and live funds are physically separate ledgers, and a reader that conflates them restates the company's revenue.
|
|
/// </summary>
|
|
bool isTest() const;
|
|
bool testIsSet() const;
|
|
void unsetTest();
|
|
void setTest(bool value);
|
|
|
|
/// <summary>
|
|
/// TransactionID is the ledger entry this charge created. It is the handle a later read or a refund names, and it is minted by the ledger rather than by the caller.
|
|
/// </summary>
|
|
utility::string_t getTransactionId() const;
|
|
bool transactionIdIsSet() const;
|
|
void unsetTransactionId();
|
|
void setTransactionId(const utility::string_t& value);
|
|
|
|
|
|
protected:
|
|
int64_t m_BalanceCents;
|
|
bool m_BalanceCentsIsSet;
|
|
|
|
utility::string_t m_ProcessorRef;
|
|
bool m_ProcessorRefIsSet;
|
|
|
|
utility::string_t m_Status;
|
|
bool m_StatusIsSet;
|
|
|
|
bool m_Test;
|
|
bool m_TestIsSet;
|
|
|
|
utility::string_t m_TransactionId;
|
|
bool m_TransactionIdIsSet;
|
|
|
|
};
|
|
|
|
|
|
}
|
|
}
|
|
|
|
#endif /* HANZO_MODEL_Charged_H_ */
|