@okutrade/account-api
Version:
TypeScript client for OKU Account API using Connect-ES
143 lines (142 loc) • 4.5 kB
TypeScript
import type { GenFile, GenMessage, GenService } from "@bufbuild/protobuf/codegenv1";
import type { Timestamp } from "@bufbuild/protobuf/wkt";
import type { JsonObject, Message } from "@bufbuild/protobuf";
/**
* Describes the file gfxcafe/oku/account/v1/preferences.proto.
*/
export declare const file_gfxcafe_oku_account_v1_preferences: GenFile;
/**
* PreferencesRequest for getting preferences
*
* @generated from message gfxcafe.oku.account.v1.PreferencesRequest
*/
export type PreferencesRequest = Message<"gfxcafe.oku.account.v1.PreferencesRequest"> & {
/**
* Optional ETag for conditional requests
*
* @generated from field: string if_none_match = 1;
*/
ifNoneMatch: string;
};
/**
* Describes the message gfxcafe.oku.account.v1.PreferencesRequest.
* Use `create(PreferencesRequestSchema)` to create a new message.
*/
export declare const PreferencesRequestSchema: GenMessage<PreferencesRequest>;
/**
* PreferencesResponse contains user preferences
*
* @generated from message gfxcafe.oku.account.v1.PreferencesResponse
*/
export type PreferencesResponse = Message<"gfxcafe.oku.account.v1.PreferencesResponse"> & {
/**
* User preferences as a JSON object
*
* @generated from field: google.protobuf.Struct preferences = 1;
*/
preferences?: JsonObject;
/**
* Version/ETag of the preferences
*
* @generated from field: string etag = 2;
*/
etag: string;
/**
* Last modified timestamp
*
* @generated from field: google.protobuf.Timestamp last_modified = 3;
*/
lastModified?: Timestamp;
};
/**
* Describes the message gfxcafe.oku.account.v1.PreferencesResponse.
* Use `create(PreferencesResponseSchema)` to create a new message.
*/
export declare const PreferencesResponseSchema: GenMessage<PreferencesResponse>;
/**
* PreferencesUpdateRequest for updating preferences
*
* @generated from message gfxcafe.oku.account.v1.PreferencesUpdateRequest
*/
export type PreferencesUpdateRequest = Message<"gfxcafe.oku.account.v1.PreferencesUpdateRequest"> & {
/**
* Updates to apply (key-value pairs)
*
* @generated from field: google.protobuf.Struct updates = 1;
*/
updates?: JsonObject;
/**
* Keys to remove
*
* @generated from field: repeated string removes = 2;
*/
removes: string[];
/**
* Optional ETag for optimistic concurrency control
*
* @generated from field: string if_match = 3;
*/
ifMatch: string;
};
/**
* Describes the message gfxcafe.oku.account.v1.PreferencesUpdateRequest.
* Use `create(PreferencesUpdateRequestSchema)` to create a new message.
*/
export declare const PreferencesUpdateRequestSchema: GenMessage<PreferencesUpdateRequest>;
/**
* PreferencesUpdateResponse after updating preferences
*
* @generated from message gfxcafe.oku.account.v1.PreferencesUpdateResponse
*/
export type PreferencesUpdateResponse = Message<"gfxcafe.oku.account.v1.PreferencesUpdateResponse"> & {
/**
* Updated preferences
*
* @generated from field: google.protobuf.Struct preferences = 1;
*/
preferences?: JsonObject;
/**
* New version/ETag
*
* @generated from field: string etag = 2;
*/
etag: string;
/**
* Last modified timestamp
*
* @generated from field: google.protobuf.Timestamp last_modified = 3;
*/
lastModified?: Timestamp;
};
/**
* Describes the message gfxcafe.oku.account.v1.PreferencesUpdateResponse.
* Use `create(PreferencesUpdateResponseSchema)` to create a new message.
*/
export declare const PreferencesUpdateResponseSchema: GenMessage<PreferencesUpdateResponse>;
/**
* PreferencesService manages user preferences
*
* @generated from service gfxcafe.oku.account.v1.PreferencesService
*/
export declare const PreferencesService: GenService<{
/**
* Get user preferences (/preferences)
*
* @generated from rpc gfxcafe.oku.account.v1.PreferencesService.Preferences
*/
preferences: {
methodKind: "unary";
input: typeof PreferencesRequestSchema;
output: typeof PreferencesResponseSchema;
};
/**
* Update user preferences (/preferences)
*
* @generated from rpc gfxcafe.oku.account.v1.PreferencesService.PreferencesUpdate
*/
preferencesUpdate: {
methodKind: "unary";
input: typeof PreferencesUpdateRequestSchema;
output: typeof PreferencesUpdateResponseSchema;
};
}>;