mirror of
https://github.com/hanzo-fi/stack.git
synced 2026-10-30 20:34:43 +00:00
80 lines
2.0 KiB
Go
80 lines
2.0 KiB
Go
// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
|
|
package operations
|
|
|
|
import (
|
|
"github.com/formancehq/stack/ledger/client/internal/utils"
|
|
"github.com/formancehq/stack/ledger/client/models/components"
|
|
"math/big"
|
|
)
|
|
|
|
type V2AddMetadataOnTransactionRequest struct {
|
|
// Name of the ledger.
|
|
Ledger string `pathParam:"style=simple,explode=false,name=ledger"`
|
|
// Transaction ID.
|
|
ID *big.Int `pathParam:"style=simple,explode=false,name=id"`
|
|
// Set the dryRun mode. Dry run mode doesn't add the logs to the database or publish a message to the message broker.
|
|
DryRun *bool `queryParam:"style=form,explode=true,name=dryRun"`
|
|
// Use an idempotency key
|
|
IdempotencyKey *string `header:"style=simple,explode=false,name=Idempotency-Key"`
|
|
// metadata
|
|
RequestBody map[string]string `request:"mediaType=application/json"`
|
|
}
|
|
|
|
func (v V2AddMetadataOnTransactionRequest) MarshalJSON() ([]byte, error) {
|
|
return utils.MarshalJSON(v, "", false)
|
|
}
|
|
|
|
func (v *V2AddMetadataOnTransactionRequest) UnmarshalJSON(data []byte) error {
|
|
if err := utils.UnmarshalJSON(data, &v, "", false, false); err != nil {
|
|
return err
|
|
}
|
|
return nil
|
|
}
|
|
|
|
func (o *V2AddMetadataOnTransactionRequest) GetLedger() string {
|
|
if o == nil {
|
|
return ""
|
|
}
|
|
return o.Ledger
|
|
}
|
|
|
|
func (o *V2AddMetadataOnTransactionRequest) GetID() *big.Int {
|
|
if o == nil {
|
|
return big.NewInt(0)
|
|
}
|
|
return o.ID
|
|
}
|
|
|
|
func (o *V2AddMetadataOnTransactionRequest) GetDryRun() *bool {
|
|
if o == nil {
|
|
return nil
|
|
}
|
|
return o.DryRun
|
|
}
|
|
|
|
func (o *V2AddMetadataOnTransactionRequest) GetIdempotencyKey() *string {
|
|
if o == nil {
|
|
return nil
|
|
}
|
|
return o.IdempotencyKey
|
|
}
|
|
|
|
func (o *V2AddMetadataOnTransactionRequest) GetRequestBody() map[string]string {
|
|
if o == nil {
|
|
return nil
|
|
}
|
|
return o.RequestBody
|
|
}
|
|
|
|
type V2AddMetadataOnTransactionResponse struct {
|
|
HTTPMeta components.HTTPMetadata `json:"-"`
|
|
}
|
|
|
|
func (o *V2AddMetadataOnTransactionResponse) GetHTTPMeta() components.HTTPMetadata {
|
|
if o == nil {
|
|
return components.HTTPMetadata{}
|
|
}
|
|
return o.HTTPMeta
|
|
}
|