@dynamic-labs/sdk-api-core 0.0.497 → 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
|
@@ -862,6 +862,73 @@ class SDKApi extends runtime.BaseAPI {
|
|
|
862
862
|
yield this.externalAuthSigninOptionsRaw(requestParameters, initOverrides);
|
|
863
863
|
});
|
|
864
864
|
}
|
|
865
|
+
/**
|
|
866
|
+
* Endpoint to verify using a token issued by an external auth provider
|
|
867
|
+
*/
|
|
868
|
+
externalAuthVerifyRaw(requestParameters, initOverrides) {
|
|
869
|
+
return _tslib.__awaiter(this, void 0, void 0, function* () {
|
|
870
|
+
if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
|
|
871
|
+
throw new runtime.RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling externalAuthVerify.');
|
|
872
|
+
}
|
|
873
|
+
if (requestParameters.externalAuthSigninRequest === null || requestParameters.externalAuthSigninRequest === undefined) {
|
|
874
|
+
throw new runtime.RequiredError('externalAuthSigninRequest', 'Required parameter requestParameters.externalAuthSigninRequest was null or undefined when calling externalAuthVerify.');
|
|
875
|
+
}
|
|
876
|
+
const queryParameters = {};
|
|
877
|
+
const headerParameters = {};
|
|
878
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
879
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
880
|
+
const token = this.configuration.accessToken;
|
|
881
|
+
const tokenString = yield token("bearerAuth", []);
|
|
882
|
+
if (tokenString) {
|
|
883
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
884
|
+
}
|
|
885
|
+
}
|
|
886
|
+
const response = yield this.request({
|
|
887
|
+
path: `/sdk/{environmentId}/externalAuth/verify`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
|
|
888
|
+
method: 'POST',
|
|
889
|
+
headers: headerParameters,
|
|
890
|
+
query: queryParameters,
|
|
891
|
+
body: ExternalAuthSigninRequest.ExternalAuthSigninRequestToJSON(requestParameters.externalAuthSigninRequest),
|
|
892
|
+
}, initOverrides);
|
|
893
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => VerifyResponse.VerifyResponseFromJSON(jsonValue));
|
|
894
|
+
});
|
|
895
|
+
}
|
|
896
|
+
/**
|
|
897
|
+
* Endpoint to verify using a token issued by an external auth provider
|
|
898
|
+
*/
|
|
899
|
+
externalAuthVerify(requestParameters, initOverrides) {
|
|
900
|
+
return _tslib.__awaiter(this, void 0, void 0, function* () {
|
|
901
|
+
const response = yield this.externalAuthVerifyRaw(requestParameters, initOverrides);
|
|
902
|
+
return yield response.value();
|
|
903
|
+
});
|
|
904
|
+
}
|
|
905
|
+
/**
|
|
906
|
+
* Options call for this endpoint
|
|
907
|
+
*/
|
|
908
|
+
externalAuthVerifyOptionsRaw(requestParameters, initOverrides) {
|
|
909
|
+
return _tslib.__awaiter(this, void 0, void 0, function* () {
|
|
910
|
+
if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
|
|
911
|
+
throw new runtime.RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling externalAuthVerifyOptions.');
|
|
912
|
+
}
|
|
913
|
+
const queryParameters = {};
|
|
914
|
+
const headerParameters = {};
|
|
915
|
+
const response = yield this.request({
|
|
916
|
+
path: `/sdk/{environmentId}/externalAuth/verify`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
|
|
917
|
+
method: 'OPTIONS',
|
|
918
|
+
headers: headerParameters,
|
|
919
|
+
query: queryParameters,
|
|
920
|
+
}, initOverrides);
|
|
921
|
+
return new runtime.VoidApiResponse(response);
|
|
922
|
+
});
|
|
923
|
+
}
|
|
924
|
+
/**
|
|
925
|
+
* Options call for this endpoint
|
|
926
|
+
*/
|
|
927
|
+
externalAuthVerifyOptions(requestParameters, initOverrides) {
|
|
928
|
+
return _tslib.__awaiter(this, void 0, void 0, function* () {
|
|
929
|
+
yield this.externalAuthVerifyOptionsRaw(requestParameters, initOverrides);
|
|
930
|
+
});
|
|
931
|
+
}
|
|
865
932
|
/**
|
|
866
933
|
* Farcaster SignIn endpoint to exchange SIWF data
|
|
867
934
|
* 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
|
@@ -858,6 +858,73 @@ class SDKApi extends BaseAPI {
|
|
|
858
858
|
yield this.externalAuthSigninOptionsRaw(requestParameters, initOverrides);
|
|
859
859
|
});
|
|
860
860
|
}
|
|
861
|
+
/**
|
|
862
|
+
* Endpoint to verify using a token issued by an external auth provider
|
|
863
|
+
*/
|
|
864
|
+
externalAuthVerifyRaw(requestParameters, initOverrides) {
|
|
865
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
866
|
+
if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
|
|
867
|
+
throw new RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling externalAuthVerify.');
|
|
868
|
+
}
|
|
869
|
+
if (requestParameters.externalAuthSigninRequest === null || requestParameters.externalAuthSigninRequest === undefined) {
|
|
870
|
+
throw new RequiredError('externalAuthSigninRequest', 'Required parameter requestParameters.externalAuthSigninRequest was null or undefined when calling externalAuthVerify.');
|
|
871
|
+
}
|
|
872
|
+
const queryParameters = {};
|
|
873
|
+
const headerParameters = {};
|
|
874
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
875
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
876
|
+
const token = this.configuration.accessToken;
|
|
877
|
+
const tokenString = yield token("bearerAuth", []);
|
|
878
|
+
if (tokenString) {
|
|
879
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
880
|
+
}
|
|
881
|
+
}
|
|
882
|
+
const response = yield this.request({
|
|
883
|
+
path: `/sdk/{environmentId}/externalAuth/verify`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
|
|
884
|
+
method: 'POST',
|
|
885
|
+
headers: headerParameters,
|
|
886
|
+
query: queryParameters,
|
|
887
|
+
body: ExternalAuthSigninRequestToJSON(requestParameters.externalAuthSigninRequest),
|
|
888
|
+
}, initOverrides);
|
|
889
|
+
return new JSONApiResponse(response, (jsonValue) => VerifyResponseFromJSON(jsonValue));
|
|
890
|
+
});
|
|
891
|
+
}
|
|
892
|
+
/**
|
|
893
|
+
* Endpoint to verify using a token issued by an external auth provider
|
|
894
|
+
*/
|
|
895
|
+
externalAuthVerify(requestParameters, initOverrides) {
|
|
896
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
897
|
+
const response = yield this.externalAuthVerifyRaw(requestParameters, initOverrides);
|
|
898
|
+
return yield response.value();
|
|
899
|
+
});
|
|
900
|
+
}
|
|
901
|
+
/**
|
|
902
|
+
* Options call for this endpoint
|
|
903
|
+
*/
|
|
904
|
+
externalAuthVerifyOptionsRaw(requestParameters, initOverrides) {
|
|
905
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
906
|
+
if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
|
|
907
|
+
throw new RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling externalAuthVerifyOptions.');
|
|
908
|
+
}
|
|
909
|
+
const queryParameters = {};
|
|
910
|
+
const headerParameters = {};
|
|
911
|
+
const response = yield this.request({
|
|
912
|
+
path: `/sdk/{environmentId}/externalAuth/verify`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
|
|
913
|
+
method: 'OPTIONS',
|
|
914
|
+
headers: headerParameters,
|
|
915
|
+
query: queryParameters,
|
|
916
|
+
}, initOverrides);
|
|
917
|
+
return new VoidApiResponse(response);
|
|
918
|
+
});
|
|
919
|
+
}
|
|
920
|
+
/**
|
|
921
|
+
* Options call for this endpoint
|
|
922
|
+
*/
|
|
923
|
+
externalAuthVerifyOptions(requestParameters, initOverrides) {
|
|
924
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
925
|
+
yield this.externalAuthVerifyOptionsRaw(requestParameters, initOverrides);
|
|
926
|
+
});
|
|
927
|
+
}
|
|
861
928
|
/**
|
|
862
929
|
* Farcaster SignIn endpoint to exchange SIWF data
|
|
863
930
|
* Farcaster provider SignIn endpoint
|