Skip to content

Commit 4d236b3

Browse files
committed
ci: regenerated with OpenAPI Doc , Speakeasy CLI 1.453.10
1 parent 15e1eac commit 4d236b3

File tree

18 files changed

+141
-34
lines changed

18 files changed

+141
-34
lines changed

.speakeasy/gen.lock

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
lockVersion: 2.0.0
22
id: 76b4d38c-5441-40d8-8002-c456a3ea1652
33
management:
4-
docChecksum: 9fbd6321083c0c2d44365ff84b8e2cb8
4+
docChecksum: 7b0a21df5c4526c3e13357d16d9397df
55
docVersion: 1.0.0
6-
speakeasyVersion: 1.453.8
6+
speakeasyVersion: 1.453.10
77
generationVersion: 2.474.15
8-
releaseVersion: 0.19.39
9-
configChecksum: c3f9d79d63560c81f4f342066e0bd2eb
8+
releaseVersion: 0.19.40
9+
configChecksum: 15a2101dcb1ac57b21ef99744782a66f
1010
repoURL: https://github.com/ding-live/ding-csharp.git
1111
repoSubDirectory: .
1212
published: true
@@ -76,6 +76,7 @@ generatedFiles:
7676
- DingSDK/Models/Requests/LookupRequest.cs
7777
- DingSDK/Models/Requests/LookupResponse.cs
7878
- DingSDK/Models/Requests/RetryResponse.cs
79+
- DingSDK/Models/Requests/Type.cs
7980
- DingSDK/Otp.cs
8081
- DingSDK/Utils/AnyDeserializer.cs
8182
- DingSDK/Utils/BigIntStrConverter.cs
@@ -138,6 +139,7 @@ generatedFiles:
138139
- docs/Models/Requests/LookupRequest.md
139140
- docs/Models/Requests/LookupResponse.md
140141
- docs/Models/Requests/RetryResponse.md
142+
- docs/Models/Requests/Type.md
141143
- docs/sdks/ding/README.md
142144
- docs/sdks/lookup/README.md
143145
- docs/sdks/otp/README.md
@@ -201,6 +203,7 @@ examples:
201203
parameters:
202204
path:
203205
phone_number: "<value>"
206+
query: {}
204207
header:
205208
customer-uuid: "69a197d9-356c-45d1-a807-41874e16b555"
206209
responses:

.speakeasy/workflow.lock

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,21 @@
1-
speakeasyVersion: 1.453.8
1+
speakeasyVersion: 1.453.10
22
sources:
33
my-source:
44
sourceNamespace: my-source
5-
sourceRevisionDigest: sha256:06f8d793d89a8ecafe709781468f719864aa6d672ddc62b39b5b29d70195073b
6-
sourceBlobDigest: sha256:4d3dd890b21d2c069d944869e00ea2505c58a172c1b06fa3cb7b59c56c21a500
5+
sourceRevisionDigest: sha256:568e72729b757e0a1b70ea06253753531e876b55234fa9ede499c590b38501c3
6+
sourceBlobDigest: sha256:1bc8346f862d17395d3ec227c51c74504f59eabaf83eb40c2932c517c8a40bf8
77
tags:
88
- latest
9-
- speakeasy-sdk-regen-1733790216
9+
- speakeasy-sdk-regen-1733876593
1010
- 1.0.0
1111
targets:
1212
DingSDK:
1313
source: my-source
1414
sourceNamespace: my-source
15-
sourceRevisionDigest: sha256:06f8d793d89a8ecafe709781468f719864aa6d672ddc62b39b5b29d70195073b
16-
sourceBlobDigest: sha256:4d3dd890b21d2c069d944869e00ea2505c58a172c1b06fa3cb7b59c56c21a500
15+
sourceRevisionDigest: sha256:568e72729b757e0a1b70ea06253753531e876b55234fa9ede499c590b38501c3
16+
sourceBlobDigest: sha256:1bc8346f862d17395d3ec227c51c74504f59eabaf83eb40c2932c517c8a40bf8
1717
codeSamplesNamespace: my-source-csharp-code-samples
18-
codeSamplesRevisionDigest: sha256:ed081ce32bfdfec0d481bebfcd9aacd18e9b3cd9931979b1264c16bd7eaf15e0
18+
codeSamplesRevisionDigest: sha256:605f515b0d950bab4281cde68ebaf7fd499c739b8c1d49d879216e1fdb678f20
1919
workflow:
2020
workflowVersion: 1.0.0
2121
speakeasyVersion: latest

DingSDK/Ding.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,10 +80,10 @@ public class Ding: IDing
8080
public SDKConfig SDKConfiguration { get; private set; }
8181

8282
private const string _language = "csharp";
83-
private const string _sdkVersion = "0.19.39";
83+
private const string _sdkVersion = "0.19.40";
8484
private const string _sdkGenVersion = "2.474.15";
8585
private const string _openapiDocVersion = "1.0.0";
86-
private const string _userAgent = "speakeasy-sdk/csharp 0.19.39 2.474.15 1.0.0 DingSDK";
86+
private const string _userAgent = "speakeasy-sdk/csharp 0.19.40 2.474.15 1.0.0 DingSDK";
8787
private string _serverUrl = "";
8888
private int _serverIndex = 0;
8989
private ISpeakeasyHttpClient _client;

DingSDK/DingSDK.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<PropertyGroup>
44
<IsPackable>true</IsPackable>
55
<PackageId>DingSDK</PackageId>
6-
<Version>0.19.39</Version>
6+
<Version>0.19.40</Version>
77
<TargetFramework>net5.0</TargetFramework>
88
<Authors>Ding</Authors>
99
<Copyright>Copyright (c) Ding 2024</Copyright>

DingSDK/Lookup.cs

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ public interface ILookup
3131
/// <summary>
3232
/// Look up for phone number
3333
/// </summary>
34-
Task<Models.Requests.LookupResponse> LookupAsync(string customerUuid, string phoneNumber);
34+
Task<Models.Requests.LookupResponse> LookupAsync(string customerUuid, string phoneNumber, List<DingSDK.Models.Requests.Type>? type = null);
3535
}
3636

3737
/// <summary>
@@ -41,10 +41,10 @@ public class Lookup: ILookup
4141
{
4242
public SDKConfig SDKConfiguration { get; private set; }
4343
private const string _language = "csharp";
44-
private const string _sdkVersion = "0.19.39";
44+
private const string _sdkVersion = "0.19.40";
4545
private const string _sdkGenVersion = "2.474.15";
4646
private const string _openapiDocVersion = "1.0.0";
47-
private const string _userAgent = "speakeasy-sdk/csharp 0.19.39 2.474.15 1.0.0 DingSDK";
47+
private const string _userAgent = "speakeasy-sdk/csharp 0.19.40 2.474.15 1.0.0 DingSDK";
4848
private string _serverUrl = "";
4949
private ISpeakeasyHttpClient _client;
5050
private Func<DingSDK.Models.Components.Security>? _securitySource;
@@ -57,12 +57,13 @@ public Lookup(ISpeakeasyHttpClient client, Func<DingSDK.Models.Components.Securi
5757
SDKConfiguration = config;
5858
}
5959

60-
public async Task<Models.Requests.LookupResponse> LookupAsync(string customerUuid, string phoneNumber)
60+
public async Task<Models.Requests.LookupResponse> LookupAsync(string customerUuid, string phoneNumber, List<DingSDK.Models.Requests.Type>? type = null)
6161
{
6262
var request = new LookupRequest()
6363
{
6464
CustomerUuid = customerUuid,
6565
PhoneNumber = phoneNumber,
66+
Type = type,
6667
};
6768
string baseUrl = this.SDKConfiguration.GetTemplatedServerUrl();
6869
var urlString = URLBuilder.Build(baseUrl, "/lookup/{phone_number}", request);

DingSDK/Models/Components/LookupResponse.cs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,12 @@ namespace DingSDK.Models.Components
1616
public class LookupResponse
1717
{
1818

19+
/// <summary>
20+
/// The CNAM (Caller ID Name) associated with the phone number. Contact us if you need to use this functionality. Once enabled, put `cnam` option to `type` query parameter.
21+
/// </summary>
22+
[JsonProperty("caller_name")]
23+
public string? CallerName { get; set; }
24+
1925
/// <summary>
2026
/// The carrier of the phone number.
2127
/// </summary>

DingSDK/Models/Requests/LookupRequest.cs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,9 @@
99
#nullable enable
1010
namespace DingSDK.Models.Requests
1111
{
12+
using DingSDK.Models.Requests;
1213
using DingSDK.Utils;
14+
using System.Collections.Generic;
1315

1416
public class LookupRequest
1517
{
@@ -19,5 +21,8 @@ public class LookupRequest
1921

2022
[SpeakeasyMetadata("pathParam:style=simple,explode=false,name=phone_number")]
2123
public string PhoneNumber { get; set; } = default!;
24+
25+
[SpeakeasyMetadata("queryParam:style=form,explode=true,name=type")]
26+
public List<DingSDK.Models.Requests.Type>? Type { get; set; }
2227
}
2328
}

DingSDK/Models/Requests/Type.cs

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
//------------------------------------------------------------------------------
2+
// <auto-generated>
3+
// This code was generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
4+
//
5+
// Changes to this file may cause incorrect behavior and will be lost when
6+
// the code is regenerated.
7+
// </auto-generated>
8+
//------------------------------------------------------------------------------
9+
#nullable enable
10+
namespace DingSDK.Models.Requests
11+
{
12+
using DingSDK.Utils;
13+
using Newtonsoft.Json;
14+
using System;
15+
16+
public enum Type
17+
{
18+
[JsonProperty("cnam")]
19+
Cnam,
20+
}
21+
22+
public static class TypeExtension
23+
{
24+
public static string Value(this Type value)
25+
{
26+
return ((JsonPropertyAttribute)value.GetType().GetMember(value.ToString())[0].GetCustomAttributes(typeof(JsonPropertyAttribute), false)[0]).PropertyName ?? value.ToString();
27+
}
28+
29+
public static Type ToEnum(this string value)
30+
{
31+
foreach(var field in typeof(Type).GetFields())
32+
{
33+
var attributes = field.GetCustomAttributes(typeof(JsonPropertyAttribute), false);
34+
if (attributes.Length == 0)
35+
{
36+
continue;
37+
}
38+
39+
var attribute = attributes[0] as JsonPropertyAttribute;
40+
if (attribute != null && attribute.PropertyName == value)
41+
{
42+
var enumVal = field.GetValue(null);
43+
44+
if (enumVal is Type)
45+
{
46+
return (Type)enumVal;
47+
}
48+
}
49+
}
50+
51+
throw new Exception($"Unknown value {value} for enum Type");
52+
}
53+
}
54+
55+
}

DingSDK/Otp.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,10 +61,10 @@ public class Otp: IOtp
6161
{
6262
public SDKConfig SDKConfiguration { get; private set; }
6363
private const string _language = "csharp";
64-
private const string _sdkVersion = "0.19.39";
64+
private const string _sdkVersion = "0.19.40";
6565
private const string _sdkGenVersion = "2.474.15";
6666
private const string _openapiDocVersion = "1.0.0";
67-
private const string _userAgent = "speakeasy-sdk/csharp 0.19.39 2.474.15 1.0.0 DingSDK";
67+
private const string _userAgent = "speakeasy-sdk/csharp 0.19.40 2.474.15 1.0.0 DingSDK";
6868
private string _serverUrl = "";
6969
private ISpeakeasyHttpClient _client;
7070
private Func<DingSDK.Models.Components.Security>? _securitySource;

NUGET.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,6 +126,7 @@ Perform a phone number lookup.
126126
```csharp
127127
using DingSDK;
128128
using DingSDK.Models.Requests;
129+
using System.Collections.Generic;
129130
using DingSDK.Models.Components;
130131

131132
var sdk = new Ding(security: new Security() {
@@ -134,7 +135,10 @@ var sdk = new Ding(security: new Security() {
134135

135136
var res = await sdk.Lookup.LookupAsync(
136137
customerUuid: "69a197d9-356c-45d1-a807-41874e16b555",
137-
phoneNumber: "<value>"
138+
phoneNumber: "<value>",
139+
type: new List<DingSDK.Models.Requests.Type>() {
140+
DingSDK.Models.Requests.Type.Cnam,
141+
}
138142
);
139143

140144
// handle response

0 commit comments

Comments
 (0)