diff --git a/demos/vc_issuer/app/generated/vc_issuer_idl.js b/demos/vc_issuer/app/generated/vc_issuer_idl.js index 665f56679b..cbafee46d7 100644 --- a/demos/vc_issuer/app/generated/vc_issuer_idl.js +++ b/demos/vc_issuer/app/generated/vc_issuer_idl.js @@ -27,6 +27,35 @@ export const idlFactory = ({ IDL }) => { 'Ok' : IssuedCredentialData, 'Err' : IssueCredentialError, }); + const HeaderField = IDL.Tuple(IDL.Text, IDL.Text); + const HttpRequest = IDL.Record({ + 'url' : IDL.Text, + 'method' : IDL.Text, + 'body' : IDL.Vec(IDL.Nat8), + 'headers' : IDL.Vec(HeaderField), + }); + const Token = IDL.Record({}); + const StreamingCallbackHttpResponse = IDL.Record({ + 'token' : IDL.Opt(Token), + 'body' : IDL.Vec(IDL.Nat8), + }); + const StreamingStrategy = IDL.Variant({ + 'Callback' : IDL.Record({ + 'token' : Token, + 'callback' : IDL.Func( + [Token], + [StreamingCallbackHttpResponse], + ['query'], + ), + }), + }); + const HttpResponse = IDL.Record({ + 'body' : IDL.Vec(IDL.Nat8), + 'headers' : IDL.Vec(HeaderField), + 'upgrade' : IDL.Opt(IDL.Bool), + 'streaming_strategy' : IDL.Opt(StreamingStrategy), + 'status_code' : IDL.Nat16, + }); const PrepareCredentialRequest = IDL.Record({ 'signed_id_alias' : SignedIdAlias, 'credential_spec' : CredentialSpec, @@ -69,6 +98,7 @@ export const idlFactory = ({ IDL }) => { [GetCredentialResponse], ['query'], ), + 'http_request' : IDL.Func([HttpRequest], [HttpResponse], ['query']), 'prepare_credential' : IDL.Func( [PrepareCredentialRequest], [PrepareCredentialResponse], diff --git a/demos/vc_issuer/app/generated/vc_issuer_types.d.ts b/demos/vc_issuer/app/generated/vc_issuer_types.d.ts index 495251809a..80f3caf58d 100644 --- a/demos/vc_issuer/app/generated/vc_issuer_types.d.ts +++ b/demos/vc_issuer/app/generated/vc_issuer_types.d.ts @@ -15,6 +15,20 @@ export interface GetCredentialRequest { } export type GetCredentialResponse = { 'Ok' : IssuedCredentialData } | { 'Err' : IssueCredentialError }; +export type HeaderField = [string, string]; +export interface HttpRequest { + 'url' : string, + 'method' : string, + 'body' : Uint8Array | number[], + 'headers' : Array, +} +export interface HttpResponse { + 'body' : Uint8Array | number[], + 'headers' : Array, + 'upgrade' : [] | [boolean], + 'streaming_strategy' : [] | [StreamingStrategy], + 'status_code' : number, +} export interface Icrc21ConsentInfo { 'consent_message' : string, 'language' : string, @@ -54,11 +68,20 @@ export interface PreparedCredentialData { 'prepared_context' : [] | [Uint8Array | number[]], } export interface SignedIdAlias { 'credential_jws' : string } +export interface StreamingCallbackHttpResponse { + 'token' : [] | [Token], + 'body' : Uint8Array | number[], +} +export type StreamingStrategy = { + 'Callback' : { 'token' : Token, 'callback' : [Principal, string] } + }; +export type Token = {}; export interface _SERVICE { 'add_employee' : ActorMethod<[Principal], string>, 'add_graduate' : ActorMethod<[Principal], string>, 'configure' : ActorMethod<[IssuerConfig], undefined>, 'get_credential' : ActorMethod<[GetCredentialRequest], GetCredentialResponse>, + 'http_request' : ActorMethod<[HttpRequest], HttpResponse>, 'prepare_credential' : ActorMethod< [PrepareCredentialRequest], PrepareCredentialResponse