Skip to content

MyJetWallet/MyJetWallet.Fireblocks.Client

Repository files navigation

Nuget version

Generate Fireblocks API Client flow

  1. Update api-spec-2.yaml

  2. Genereate ApiClients.cs from console:

    dotnet new tool-manifest --force

    dotnet tool install NSwag.ConsoleCore

    dotnet nswag version

    dotnet nswag run nswag.json

  3. In ApiClients.cs replace:

    • status_ == 5XX -> status_ >= 500 && status_ < 600

    • public ExternalCorrelationData ExternalCorrelationData -> public CorrelationData ExternalCorrelationData

    • System.Threading.Tasks.Task<Response> ExecutePostAsync -> System.Threading.Tasks.Task<Response> WorkflowExecutePostAsync

    • System.Threading.Tasks.Task<Response> PositionsGetAsync(string id -> System.Threading.Tasks.Task<Response> PositionsGetByIdAsync(string id

    • System.Collections.Generic.List -> System.Collections.Generic.List

    In class CreateWorkflowConfigurationRequest:

    • public System.Collections.Generic.List ConfigOperations { get; set; } = new System.Collections.Generic.List(); -> public System.Collections.Generic.List ConfigOperations { get; set; } = new System.Collections.Generic.List();

    In class WorkflowConfiguration:

    • public System.Collections.Generic.List ConfigOperations { get; set; } = new System.Collections.Generic.List(); -> public System.Collections.Generic.List ConfigOperations { get; set; } = new System.Collections.Generic.List();

    In class WorkflowConfigurationSnapshot:

    • public System.Collections.Generic.List ConfigOperations { get; set; } = new System.Collections.Generic.List(); -> public System.Collections.Generic.List ConfigOperations { get; set; } = new System.Collections.Generic.List();

    In class WorkflowExecution:

    • public System.Collections.Generic.List ExecutionOperations { get; set; } = new System.Collections.Generic.List(); -> public System.Collections.Generic.List ExecutionOperations { get; set; } = new System.Collections.Generic.List();

    In class class TransactionResponse:

    • [Newtonsoft.Json.JsonProperty("externalTxId", Required = Newtonsoft.Json.Required.DisallowNull, NullValueHandling = Newtonsoft.Json.NullValueHandling.Ignore)] -> [Newtonsoft.Json.JsonProperty("externalTxId", Required = Newtonsoft.Json.Required.Default, NullValueHandling = Newtonsoft.Json.NullValueHandling.Ignore)]

    • [Newtonsoft.Json.JsonProperty("customerRefId", Required = Newtonsoft.Json.Required.DisallowNull, NullValueHandling = Newtonsoft.Json.NullValueHandling.Ignore)] -> [Newtonsoft.Json.JsonProperty("customerRefId", Required = Newtonsoft.Json.Required.Default, NullValueHandling = Newtonsoft.Json.NullValueHandling.Ignore)]

    In class class TransactionsClient:

    • public partial class TransactionsClient : BaseClient, ITransactionsClient -> public partial class TransactionsClient : BaseClient, ITransactionsClient, ITransactionsAdminClient, ITransactionsSignerClient
  4. Add to enum AssetTypeResponseType:

    [System.Runtime.Serialization.EnumMember(Value = @"TON_ASSET")]
    TON_ASSET = 11,
    
    [System.Runtime.Serialization.EnumMember(Value = @"ETH_CONTRACT")]
    ETH_CONTRACT = 12,
    
    [System.Runtime.Serialization.EnumMember(Value = @"XRP_ASSET")]
    XRP_ASSET = 13
    
  5. Add to enum ExchangeType:

     [System.Runtime.Serialization.EnumMember(Value = @"BYBIT_V2")]
     BYBIT_V2 = 26,
    

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors 4

  •  
  •  
  •  
  •  

Languages