Skip to content

Commit

Permalink
ci: regenerated with OpenAPI Doc , Speakeasy CLI 1.396.6 (#301)
Browse files Browse the repository at this point in the history
Co-authored-by: speakeasybot <bot@speakeasyapi.dev>
  • Loading branch information
github-actions[bot] and speakeasybot committed Sep 13, 2024
1 parent 0a49ddf commit fc053f2
Show file tree
Hide file tree
Showing 289 changed files with 4,350 additions and 2,512 deletions.
14 changes: 14 additions & 0 deletions .speakeasy/workflow.lock
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,13 @@ sources:
tags:
- latest
- main
sync-for-commerce-source:
sourceNamespace: sync-for-commerce-source
sourceRevisionDigest: sha256:25f68f6f72e255804ffe90049b3b15b1dd8dcb78e7f96954e1ec5852799fc13f
sourceBlobDigest: sha256:ab64a148f650a63d3411abb1686ffdcc252ddb1525415957d2dcd7e818882594
tags:
- latest
- main
targets:
bank-feeds-library:
source: bank-feeds-source
Expand All @@ -37,6 +44,11 @@ targets:
sourceNamespace: platform-source
sourceRevisionDigest: sha256:63cd9348c74d8931dbcbeaefdb72a6d1d62e739c2863ffd9eaee728cc1f61f98
sourceBlobDigest: sha256:e1e3f4c3ed16022322bc656bb0e4ef28c04fff8c92c271cc859c6e2b32af5613
sync-for-commerce-library:
source: sync-for-commerce-source
sourceNamespace: sync-for-commerce-source
sourceRevisionDigest: sha256:25f68f6f72e255804ffe90049b3b15b1dd8dcb78e7f96954e1ec5852799fc13f
sourceBlobDigest: sha256:ab64a148f650a63d3411abb1686ffdcc252ddb1525415957d2dcd7e818882594
workflow:
workflowVersion: 1.0.0
speakeasyVersion: latest
Expand All @@ -59,6 +71,8 @@ workflow:
sync-for-commerce-source:
inputs:
- location: https://raw.githubusercontent.com/codatio/oas/main/yaml/Codat-Sync-Commerce.yaml
registry:
location: registry.speakeasyapi.dev/codat/codat/sync-for-commerce-source
sync-for-expenses-source:
inputs:
- location: https://raw.githubusercontent.com/codatio/oas/main/yaml/Codat-Sync-Expenses.yaml
Expand Down
2 changes: 2 additions & 0 deletions .speakeasy/workflow.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ sources:
sync-for-commerce-source:
inputs:
- location: https://raw.githubusercontent.com/codatio/oas/main/yaml/Codat-Sync-Commerce.yaml
registry:
location: registry.speakeasyapi.dev/codat/codat/sync-for-commerce-source
sync-for-expenses-source:
inputs:
- location: https://raw.githubusercontent.com/codatio/oas/main/yaml/Codat-Sync-Expenses.yaml
Expand Down
800 changes: 560 additions & 240 deletions sync-for-commerce/.speakeasy/gen.lock

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion sync-for-commerce/.speakeasy/gen.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,4 +35,4 @@ csharp:
outputModelSuffix: output
packageName: Codat.Sync.Commerce
packageTags: ""
responseFormat: envelope
responseFormat: envelope
26 changes: 26 additions & 0 deletions sync-for-commerce/CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# Contributing to This Repository

Thank you for your interest in contributing to this repository. Please note that this repository contains generated code. As such, we do not accept direct changes or pull requests. Instead, we encourage you to follow the guidelines below to report issues and suggest improvements.

## How to Report Issues

If you encounter any bugs or have suggestions for improvements, please open an issue on GitHub. When reporting an issue, please provide as much detail as possible to help us reproduce the problem. This includes:

- A clear and descriptive title
- Steps to reproduce the issue
- Expected and actual behavior
- Any relevant logs, screenshots, or error messages
- Information about your environment (e.g., operating system, software versions)
- For example can be collected using the `npx envinfo` command from your terminal if you have Node.js installed

## Issue Triage and Upstream Fixes

We will review and triage issues as quickly as possible. Our goal is to address bugs and incorporate improvements in the upstream source code. Fixes will be included in the next generation of the generated code.

## Contact

If you have any questions or need further assistance, please feel free to reach out by opening an issue.

Thank you for your understanding and cooperation!

The Maintainers
296 changes: 220 additions & 76 deletions sync-for-commerce/Codat/Sync/Commerce/AdvancedControls.cs

Large diffs are not rendered by default.

49 changes: 41 additions & 8 deletions sync-for-commerce/Codat/Sync/Commerce/Codat.Sync.Commerce.csproj
Original file line number Diff line number Diff line change
@@ -1,22 +1,55 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<IsPackable>true</IsPackable>
<PackageId>Codat.Sync.Commerce</PackageId>
<Version>3.1.0</Version>
<Version>4.0.0</Version>
<TargetFramework>net8.0</TargetFramework>
<Authors>Codat</Authors>
<TargetFramework>net6.0</TargetFramework>
<Copyright>Copyright (c) Codat 2024</Copyright>
<RepositoryUrl>https://github.com/codatio/client-sdk-csharp.git</RepositoryUrl>
<RepositoryType>git</RepositoryType>
<Description>Sync for Commerce: The API for Sync for Commerce.

Sync for Commerce automatically replicates and reconciles sales data from a merchant’s source PoS, Payments, and eCommerce systems into their accounting software. This eliminates manual processing by merchants and transforms their ability to run and grow their business.

[Explore product](https://docs.codat.io/commerce/overview) | [See our OpenAPI spec](https://github.com/codatio/oas)

Not seeing the endpoints you're expecting? We've [reorganized our products](https://docs.codat.io/updates/230901-new-products), and you may be using a [different version of Sync for Commerce](https://docs.codat.io/sync-for-commerce-v1-api#/).

---

<!-- Start Codat Tags Table -->
## Endpoints

| Endpoints | Description |
| :- |:- |
| Connections | Create new and manage existing data connections for a company. |
| Sync | Initiate data syncs and monitor their status. |
| Sync flow settings | Control text and visibility settings for the Sync Flow. |
| Integrations | Get a list of integrations supported by Sync for Commerce and their logos. |
| Advanced controls | View and manage mapping configured for a company's commerce sync. |
<!-- End Codat Tags Table --></Description>
</PropertyGroup>

<PropertyGroup>
<Nullable>enable</Nullable>
<PackageReadmeFile>README.md</PackageReadmeFile>
<GenerateDocumentationFile>true</GenerateDocumentationFile>
<NoWarn>1591</NoWarn>
<RepositoryUrl>https://github.com/codatio/client-sdk-csharp</RepositoryUrl>
</PropertyGroup>

<PropertyGroup>
<GenerateDocumentationFile>true</GenerateDocumentationFile>
<PackageReadmeFile>README.md</PackageReadmeFile>
</PropertyGroup>

<ItemGroup>
<None Include="../README.md" Pack="true" PackagePath="/"/>
<None Include="../docs/*" Pack="true" PackagePath="/docs"/>
<None Include="..\..\..\NUGET.md" Pack="true" PackagePath="README.md"/>
<None Include="..\..\..\docs\**\*" Pack="true" PackagePath="\docs" CopyToOutputDirectory="PreserveNewest"/>
</ItemGroup>

<ItemGroup>
<PackageReference Include="newtonsoft.json" Version="13.0.3" />
<PackageReference Include="nodatime" Version="3.1.9" />
</ItemGroup>
</Project>

</Project>
72 changes: 37 additions & 35 deletions sync-for-commerce/Codat/Sync/Commerce/CodatSyncCommerce.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@

//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by Speakeasy (https://speakeasyapi.dev). DO NOT EDIT.
// This code was generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
//
// Changes to this file may cause incorrect behavior and will be lost when
// the code is regenerated.
Expand All @@ -11,8 +10,9 @@
namespace Codat.Sync.Commerce
{
using Codat.Sync.Commerce.Hooks;
using Codat.Sync.Commerce.Models.Components;
using Codat.Sync.Commerce.Models.Errors;
using Codat.Sync.Commerce.Models.Shared;
using Codat.Sync.Commerce.Utils.Retries;
using Codat.Sync.Commerce.Utils;
using Newtonsoft.Json;
using System.Collections.Generic;
Expand Down Expand Up @@ -50,29 +50,29 @@ public interface ICodatSyncCommerce
{

/// <summary>
/// Control text and visibility settings for the Sync Flow.
/// Create new and manage existing data connections for a company.
/// </summary>
public ISyncFlowSettings SyncFlowSettings { get; }
public IConnections Connections { get; }

/// <summary>
/// View and manage mapping configured for a company&apos;s commerce sync.
/// </summary>
public IAdvancedControls AdvancedControls { get; }

/// <summary>
/// Create new and manage existing data connections for a company.
/// Get a list of integrations supported by Sync for Commerce and their logos.
/// </summary>
public IConnections Connections { get; }
public IIntegrations Integrations { get; }

/// <summary>
/// Initiate data syncs and monitor their status.
/// Control text and visibility settings for the Sync Flow.
/// </summary>
public ISync Sync { get; }
public ISyncFlowSettings SyncFlowSettings { get; }

/// <summary>
/// Get a list of integrations supported by Sync for Commerce and their logos.
/// Initiate data syncs and monitor their status.
/// </summary>
public IIntegrations Integrations { get; }
public ISync Sync { get; }
}

public class SDKConfig
Expand All @@ -86,7 +86,8 @@ public class SDKConfig

public string ServerUrl = "";
public int ServerIndex = 0;
public SDKHooks hooks = new SDKHooks();
public SDKHooks Hooks = new SDKHooks();
public RetryConfig? RetryConfig = null;

public string GetTemplatedServerUrl()
{
Expand All @@ -100,7 +101,7 @@ public string GetTemplatedServerUrl()
public ISpeakeasyHttpClient InitHooks(ISpeakeasyHttpClient client)
{
string preHooksUrl = GetTemplatedServerUrl();
var (postHooksUrl, postHooksClient) = this.hooks.SDKInit(preHooksUrl, client);
var (postHooksUrl, postHooksClient) = this.Hooks.SDKInit(preHooksUrl, client);
if (preHooksUrl != postHooksUrl)
{
this.ServerUrl = postHooksUrl;
Expand Down Expand Up @@ -140,21 +141,21 @@ public class CodatSyncCommerce: ICodatSyncCommerce
public SDKConfig SDKConfiguration { get; private set; }

private const string _language = "csharp";
private const string _sdkVersion = "3.1.0";
private const string _sdkGenVersion = "2.319.7";
private const string _sdkVersion = "4.0.0";
private const string _sdkGenVersion = "2.415.6";
private const string _openapiDocVersion = "1.1";
private const string _userAgent = "speakeasy-sdk/csharp 3.1.0 2.319.7 1.1 Codat.Sync.Commerce";
private const string _userAgent = "speakeasy-sdk/csharp 4.0.0 2.415.6 1.1 Codat.Sync.Commerce";
private string _serverUrl = "";
private int _serverIndex = 0;
private ISpeakeasyHttpClient _defaultClient;
private Func<Security>? _securitySource;
public ISyncFlowSettings SyncFlowSettings { get; private set; }
public IAdvancedControls AdvancedControls { get; private set; }
private ISpeakeasyHttpClient _client;
private Func<Codat.Sync.Commerce.Models.Components.Security>? _securitySource;
public IConnections Connections { get; private set; }
public ISync Sync { get; private set; }
public IAdvancedControls AdvancedControls { get; private set; }
public IIntegrations Integrations { get; private set; }
public ISyncFlowSettings SyncFlowSettings { get; private set; }
public ISync Sync { get; private set; }

public CodatSyncCommerce(Security? security = null, Func<Security>? securitySource = null, int? serverIndex = null, string? serverUrl = null, Dictionary<string, string>? urlParams = null, ISpeakeasyHttpClient? client = null)
public CodatSyncCommerce(string? authHeader = null, Func<string>? authHeaderSource = null, int? serverIndex = null, string? serverUrl = null, Dictionary<string, string>? urlParams = null, ISpeakeasyHttpClient? client = null, RetryConfig? retryConfig = null)
{
if (serverIndex != null)
{
Expand All @@ -174,43 +175,44 @@ public CodatSyncCommerce(Security? security = null, Func<Security>? securitySour
_serverUrl = serverUrl;
}

_defaultClient = new SpeakeasyHttpClient(client);
_client = client ?? new SpeakeasyHttpClient();

if(securitySource != null)
if(authHeaderSource != null)
{
_securitySource = securitySource;
_securitySource = () => new Codat.Sync.Commerce.Models.Components.Security() { AuthHeader = authHeaderSource() };
}
else if(security != null)
else if(authHeader != null)
{
_securitySource = () => security;
_securitySource = () => new Codat.Sync.Commerce.Models.Components.Security() { AuthHeader = authHeader };
}
else
{
throw new Exception("security and securitySource cannot both be null");
throw new Exception("authHeader and authHeaderSource cannot both be null");
}

SDKConfiguration = new SDKConfig()
{
ServerIndex = _serverIndex,
ServerUrl = _serverUrl
ServerUrl = _serverUrl,
RetryConfig = retryConfig
};

_defaultClient = SDKConfiguration.InitHooks(_defaultClient);
_client = SDKConfiguration.InitHooks(_client);


SyncFlowSettings = new SyncFlowSettings(_defaultClient, _securitySource, _serverUrl, SDKConfiguration);
Connections = new Connections(_client, _securitySource, _serverUrl, SDKConfiguration);


AdvancedControls = new AdvancedControls(_defaultClient, _securitySource, _serverUrl, SDKConfiguration);
AdvancedControls = new AdvancedControls(_client, _securitySource, _serverUrl, SDKConfiguration);


Connections = new Connections(_defaultClient, _securitySource, _serverUrl, SDKConfiguration);
Integrations = new Integrations(_client, _securitySource, _serverUrl, SDKConfiguration);


Sync = new Sync(_defaultClient, _securitySource, _serverUrl, SDKConfiguration);
SyncFlowSettings = new SyncFlowSettings(_client, _securitySource, _serverUrl, SDKConfiguration);


Integrations = new Integrations(_defaultClient, _securitySource, _serverUrl, SDKConfiguration);
Sync = new Sync(_client, _securitySource, _serverUrl, SDKConfiguration);
}
}
}
Loading

0 comments on commit fc053f2

Please sign in to comment.