@hashgraphonline/standards-sdk 0.0.6 → 0.0.8

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.
@@ -0,0 +1,27 @@
1
+ import { InscriptionOptions, InscriptionResult, RetrievedInscriptionResult, HederaClientConfig, DAppSigner } from './types';
2
+ export type InscriptionInput = {
3
+ type: 'url';
4
+ url: string;
5
+ } | {
6
+ type: 'file';
7
+ path: string;
8
+ } | {
9
+ type: 'buffer';
10
+ buffer: ArrayBuffer | Buffer;
11
+ fileName: string;
12
+ mimeType?: string;
13
+ };
14
+ export type InscriptionResponse = {
15
+ confirmed: false;
16
+ result: InscriptionResult;
17
+ } | {
18
+ confirmed: true;
19
+ result: InscriptionResult;
20
+ inscription: RetrievedInscriptionResult;
21
+ };
22
+ export declare function inscribe(input: InscriptionInput, clientConfig: HederaClientConfig, options: InscriptionOptions): Promise<InscriptionResponse>;
23
+ export declare function inscribeWithSigner(input: InscriptionInput, signer: DAppSigner, options: InscriptionOptions): Promise<InscriptionResponse>;
24
+ export declare function retrieveInscription(transactionId: string, options: InscriptionOptions & {
25
+ accountId?: string;
26
+ privateKey?: string;
27
+ }): Promise<RetrievedInscriptionResult>;
@@ -0,0 +1,78 @@
1
+ import { StartInscriptionRequest, InscriptionResult, RetrievedInscriptionResult as SDKRetrievedInscriptionResult, HederaClientConfig, InscriptionNumbersParams, InscriptionNumberDetails } from '@kiloscribe/inscription-sdk';
2
+ import { DAppSigner as HederaDAppSigner } from '@hashgraph/hedera-wallet-connect';
3
+ import { LoggerOptions } from '../utils/logger';
4
+ export type { StartInscriptionRequest, InscriptionResult, InscriptionNumbersParams, InscriptionNumberDetails };
5
+ export interface RetrievedInscriptionResult extends SDKRetrievedInscriptionResult {
6
+ content?: string;
7
+ url?: string;
8
+ metadata?: Record<string, unknown>;
9
+ }
10
+ export type { HederaClientConfig };
11
+ export type DAppSigner = HederaDAppSigner;
12
+ export interface AuthConfig {
13
+ accountId: string;
14
+ privateKey: string;
15
+ network?: 'mainnet' | 'testnet';
16
+ }
17
+ export interface AuthResult {
18
+ token: string;
19
+ expiresAt: number;
20
+ }
21
+ export interface InscriptionSDKOptions {
22
+ apiKey?: string;
23
+ network?: 'mainnet' | 'testnet';
24
+ }
25
+ export interface InscriptionOptions {
26
+ network?: 'mainnet' | 'testnet';
27
+ apiKey?: string;
28
+ baseUrl?: string;
29
+ maxRetries?: number;
30
+ retryDelay?: number;
31
+ waitForConfirmation?: boolean;
32
+ waitMaxAttempts?: number;
33
+ waitIntervalMs?: number;
34
+ logging?: LoggerOptions;
35
+ metadata?: Record<string, unknown>;
36
+ tags?: string[];
37
+ chunkSize?: number;
38
+ mode?: 'file' | 'upload' | 'hashinal' | 'hashinal-collection';
39
+ jsonFileURL?: string;
40
+ }
41
+ export interface TextInscriptionOptions extends InscriptionOptions {
42
+ contentType?: string;
43
+ metadata?: Record<string, unknown>;
44
+ tags?: string[];
45
+ }
46
+ export interface FileInscriptionOptions extends InscriptionOptions {
47
+ contentType?: string;
48
+ metadata?: Record<string, unknown>;
49
+ tags?: string[];
50
+ chunkSize?: number;
51
+ }
52
+ export interface UrlInscriptionOptions extends InscriptionOptions {
53
+ metadata?: Record<string, unknown> & {
54
+ name?: string;
55
+ description?: string;
56
+ tags?: string[];
57
+ };
58
+ tags?: string[];
59
+ maxFileSize?: number;
60
+ }
61
+ export interface HashinalInscriptionOptions extends InscriptionOptions {
62
+ metadata: {
63
+ name: string;
64
+ creator: string;
65
+ description: string;
66
+ image?: string;
67
+ type: string;
68
+ attributes?: Array<{
69
+ trait_type: string;
70
+ value: string | number;
71
+ }>;
72
+ properties?: Record<string, unknown>;
73
+ tags?: string[];
74
+ [key: string]: unknown;
75
+ };
76
+ jsonFileURL?: string;
77
+ chunkSize?: number;
78
+ }