@dynamic-labs/sdk-api 0.0.498 → 0.0.499
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/apis/SDKApi.cjs +67 -0
- package/src/apis/SDKApi.d.ts +23 -0
- package/src/apis/SDKApi.js +67 -0
package/package.json
CHANGED
package/src/apis/SDKApi.cjs
CHANGED
|
@@ -880,6 +880,73 @@ class SDKApi extends runtime.BaseAPI {
|
|
|
880
880
|
yield this.externalAuthSigninOptionsRaw(requestParameters, initOverrides);
|
|
881
881
|
});
|
|
882
882
|
}
|
|
883
|
+
/**
|
|
884
|
+
* Endpoint to verify using a token issued by an external auth provider
|
|
885
|
+
*/
|
|
886
|
+
externalAuthVerifyRaw(requestParameters, initOverrides) {
|
|
887
|
+
return _tslib.__awaiter(this, void 0, void 0, function* () {
|
|
888
|
+
if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
|
|
889
|
+
throw new runtime.RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling externalAuthVerify.');
|
|
890
|
+
}
|
|
891
|
+
if (requestParameters.externalAuthSigninRequest === null || requestParameters.externalAuthSigninRequest === undefined) {
|
|
892
|
+
throw new runtime.RequiredError('externalAuthSigninRequest', 'Required parameter requestParameters.externalAuthSigninRequest was null or undefined when calling externalAuthVerify.');
|
|
893
|
+
}
|
|
894
|
+
const queryParameters = {};
|
|
895
|
+
const headerParameters = {};
|
|
896
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
897
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
898
|
+
const token = this.configuration.accessToken;
|
|
899
|
+
const tokenString = yield token("bearerAuth", []);
|
|
900
|
+
if (tokenString) {
|
|
901
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
902
|
+
}
|
|
903
|
+
}
|
|
904
|
+
const response = yield this.request({
|
|
905
|
+
path: `/sdk/{environmentId}/externalAuth/verify`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
|
|
906
|
+
method: 'POST',
|
|
907
|
+
headers: headerParameters,
|
|
908
|
+
query: queryParameters,
|
|
909
|
+
body: ExternalAuthSigninRequest.ExternalAuthSigninRequestToJSON(requestParameters.externalAuthSigninRequest),
|
|
910
|
+
}, initOverrides);
|
|
911
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => VerifyResponse.VerifyResponseFromJSON(jsonValue));
|
|
912
|
+
});
|
|
913
|
+
}
|
|
914
|
+
/**
|
|
915
|
+
* Endpoint to verify using a token issued by an external auth provider
|
|
916
|
+
*/
|
|
917
|
+
externalAuthVerify(requestParameters, initOverrides) {
|
|
918
|
+
return _tslib.__awaiter(this, void 0, void 0, function* () {
|
|
919
|
+
const response = yield this.externalAuthVerifyRaw(requestParameters, initOverrides);
|
|
920
|
+
return yield response.value();
|
|
921
|
+
});
|
|
922
|
+
}
|
|
923
|
+
/**
|
|
924
|
+
* Options call for this endpoint
|
|
925
|
+
*/
|
|
926
|
+
externalAuthVerifyOptionsRaw(requestParameters, initOverrides) {
|
|
927
|
+
return _tslib.__awaiter(this, void 0, void 0, function* () {
|
|
928
|
+
if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
|
|
929
|
+
throw new runtime.RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling externalAuthVerifyOptions.');
|
|
930
|
+
}
|
|
931
|
+
const queryParameters = {};
|
|
932
|
+
const headerParameters = {};
|
|
933
|
+
const response = yield this.request({
|
|
934
|
+
path: `/sdk/{environmentId}/externalAuth/verify`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
|
|
935
|
+
method: 'OPTIONS',
|
|
936
|
+
headers: headerParameters,
|
|
937
|
+
query: queryParameters,
|
|
938
|
+
}, initOverrides);
|
|
939
|
+
return new runtime.VoidApiResponse(response);
|
|
940
|
+
});
|
|
941
|
+
}
|
|
942
|
+
/**
|
|
943
|
+
* Options call for this endpoint
|
|
944
|
+
*/
|
|
945
|
+
externalAuthVerifyOptions(requestParameters, initOverrides) {
|
|
946
|
+
return _tslib.__awaiter(this, void 0, void 0, function* () {
|
|
947
|
+
yield this.externalAuthVerifyOptionsRaw(requestParameters, initOverrides);
|
|
948
|
+
});
|
|
949
|
+
}
|
|
883
950
|
/**
|
|
884
951
|
* Farcaster SignIn endpoint to exchange SIWF data
|
|
885
952
|
* Farcaster provider SignIn endpoint
|
package/src/apis/SDKApi.d.ts
CHANGED
|
@@ -94,6 +94,13 @@ export interface ExternalAuthSigninOperationRequest {
|
|
|
94
94
|
export interface ExternalAuthSigninOptionsRequest {
|
|
95
95
|
environmentId: string;
|
|
96
96
|
}
|
|
97
|
+
export interface ExternalAuthVerifyRequest {
|
|
98
|
+
environmentId: string;
|
|
99
|
+
externalAuthSigninRequest: ExternalAuthSigninRequest;
|
|
100
|
+
}
|
|
101
|
+
export interface ExternalAuthVerifyOptionsRequest {
|
|
102
|
+
environmentId: string;
|
|
103
|
+
}
|
|
97
104
|
export interface FarcasterSignInOperationRequest {
|
|
98
105
|
environmentId: string;
|
|
99
106
|
farcasterSignInRequest?: FarcasterSignInRequest;
|
|
@@ -690,6 +697,22 @@ export declare class SDKApi extends runtime.BaseAPI {
|
|
|
690
697
|
* Options call for this endpoint
|
|
691
698
|
*/
|
|
692
699
|
externalAuthSigninOptions(requestParameters: ExternalAuthSigninOptionsRequest, initOverrides?: RequestInit): Promise<void>;
|
|
700
|
+
/**
|
|
701
|
+
* Endpoint to verify using a token issued by an external auth provider
|
|
702
|
+
*/
|
|
703
|
+
externalAuthVerifyRaw(requestParameters: ExternalAuthVerifyRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<VerifyResponse>>;
|
|
704
|
+
/**
|
|
705
|
+
* Endpoint to verify using a token issued by an external auth provider
|
|
706
|
+
*/
|
|
707
|
+
externalAuthVerify(requestParameters: ExternalAuthVerifyRequest, initOverrides?: RequestInit): Promise<VerifyResponse>;
|
|
708
|
+
/**
|
|
709
|
+
* Options call for this endpoint
|
|
710
|
+
*/
|
|
711
|
+
externalAuthVerifyOptionsRaw(requestParameters: ExternalAuthVerifyOptionsRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<void>>;
|
|
712
|
+
/**
|
|
713
|
+
* Options call for this endpoint
|
|
714
|
+
*/
|
|
715
|
+
externalAuthVerifyOptions(requestParameters: ExternalAuthVerifyOptionsRequest, initOverrides?: RequestInit): Promise<void>;
|
|
693
716
|
/**
|
|
694
717
|
* Farcaster SignIn endpoint to exchange SIWF data
|
|
695
718
|
* Farcaster provider SignIn endpoint
|
package/src/apis/SDKApi.js
CHANGED
|
@@ -876,6 +876,73 @@ class SDKApi extends BaseAPI {
|
|
|
876
876
|
yield this.externalAuthSigninOptionsRaw(requestParameters, initOverrides);
|
|
877
877
|
});
|
|
878
878
|
}
|
|
879
|
+
/**
|
|
880
|
+
* Endpoint to verify using a token issued by an external auth provider
|
|
881
|
+
*/
|
|
882
|
+
externalAuthVerifyRaw(requestParameters, initOverrides) {
|
|
883
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
884
|
+
if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
|
|
885
|
+
throw new RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling externalAuthVerify.');
|
|
886
|
+
}
|
|
887
|
+
if (requestParameters.externalAuthSigninRequest === null || requestParameters.externalAuthSigninRequest === undefined) {
|
|
888
|
+
throw new RequiredError('externalAuthSigninRequest', 'Required parameter requestParameters.externalAuthSigninRequest was null or undefined when calling externalAuthVerify.');
|
|
889
|
+
}
|
|
890
|
+
const queryParameters = {};
|
|
891
|
+
const headerParameters = {};
|
|
892
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
893
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
894
|
+
const token = this.configuration.accessToken;
|
|
895
|
+
const tokenString = yield token("bearerAuth", []);
|
|
896
|
+
if (tokenString) {
|
|
897
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
898
|
+
}
|
|
899
|
+
}
|
|
900
|
+
const response = yield this.request({
|
|
901
|
+
path: `/sdk/{environmentId}/externalAuth/verify`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
|
|
902
|
+
method: 'POST',
|
|
903
|
+
headers: headerParameters,
|
|
904
|
+
query: queryParameters,
|
|
905
|
+
body: ExternalAuthSigninRequestToJSON(requestParameters.externalAuthSigninRequest),
|
|
906
|
+
}, initOverrides);
|
|
907
|
+
return new JSONApiResponse(response, (jsonValue) => VerifyResponseFromJSON(jsonValue));
|
|
908
|
+
});
|
|
909
|
+
}
|
|
910
|
+
/**
|
|
911
|
+
* Endpoint to verify using a token issued by an external auth provider
|
|
912
|
+
*/
|
|
913
|
+
externalAuthVerify(requestParameters, initOverrides) {
|
|
914
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
915
|
+
const response = yield this.externalAuthVerifyRaw(requestParameters, initOverrides);
|
|
916
|
+
return yield response.value();
|
|
917
|
+
});
|
|
918
|
+
}
|
|
919
|
+
/**
|
|
920
|
+
* Options call for this endpoint
|
|
921
|
+
*/
|
|
922
|
+
externalAuthVerifyOptionsRaw(requestParameters, initOverrides) {
|
|
923
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
924
|
+
if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
|
|
925
|
+
throw new RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling externalAuthVerifyOptions.');
|
|
926
|
+
}
|
|
927
|
+
const queryParameters = {};
|
|
928
|
+
const headerParameters = {};
|
|
929
|
+
const response = yield this.request({
|
|
930
|
+
path: `/sdk/{environmentId}/externalAuth/verify`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
|
|
931
|
+
method: 'OPTIONS',
|
|
932
|
+
headers: headerParameters,
|
|
933
|
+
query: queryParameters,
|
|
934
|
+
}, initOverrides);
|
|
935
|
+
return new VoidApiResponse(response);
|
|
936
|
+
});
|
|
937
|
+
}
|
|
938
|
+
/**
|
|
939
|
+
* Options call for this endpoint
|
|
940
|
+
*/
|
|
941
|
+
externalAuthVerifyOptions(requestParameters, initOverrides) {
|
|
942
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
943
|
+
yield this.externalAuthVerifyOptionsRaw(requestParameters, initOverrides);
|
|
944
|
+
});
|
|
945
|
+
}
|
|
879
946
|
/**
|
|
880
947
|
* Farcaster SignIn endpoint to exchange SIWF data
|
|
881
948
|
* Farcaster provider SignIn endpoint
|