mirror of
https://github.com/Xahau/xahau.js.git
synced 2025-12-06 17:27:59 +00:00
add AccountNamespace and fix metadata
This commit is contained in:
47
packages/xrpl/src/models/methods/accountNamespace.ts
Normal file
47
packages/xrpl/src/models/methods/accountNamespace.ts
Normal file
@@ -0,0 +1,47 @@
|
|||||||
|
import { LedgerIndex } from '../common'
|
||||||
|
import { AccountRoot, HookState, SignerList } from '../ledger'
|
||||||
|
|
||||||
|
import { BaseRequest, BaseResponse } from './baseMethod'
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The `account_namespace` command retrieves the account namespace. All information retrieved is relative to a
|
||||||
|
* particular version of the ledger. Returns an {@link AccountNamespaceResponse}.
|
||||||
|
*
|
||||||
|
* @category Requests
|
||||||
|
*/
|
||||||
|
export interface AccountNamespaceRequest extends BaseRequest {
|
||||||
|
command: 'account_namespace'
|
||||||
|
/** A unique identifier for the account, most commonly the account's address. */
|
||||||
|
account: string
|
||||||
|
/** The hex namespace. */
|
||||||
|
namespace_id?: string
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Response expected from an {@link AccountNamespaceRequest}.
|
||||||
|
*
|
||||||
|
* @category Responses
|
||||||
|
*/
|
||||||
|
export interface AccountNamespaceResponse extends BaseResponse {
|
||||||
|
result: {
|
||||||
|
/**
|
||||||
|
* The account requested.
|
||||||
|
*/
|
||||||
|
account: string
|
||||||
|
/**
|
||||||
|
* The namespace_id requested.
|
||||||
|
*/
|
||||||
|
namespace_id: string
|
||||||
|
/**
|
||||||
|
* A list of HookStates for the specified account namespace_id.
|
||||||
|
*/
|
||||||
|
namespace_entries: HookState[]
|
||||||
|
/**
|
||||||
|
* The ledger index of the current open ledger, which was used when
|
||||||
|
* retrieving this information.
|
||||||
|
*/
|
||||||
|
ledger_current_index: number
|
||||||
|
/** If true, this data comes from a validated ledger. */
|
||||||
|
validated: boolean
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -8,6 +8,10 @@ import {
|
|||||||
} from './accountCurrencies'
|
} from './accountCurrencies'
|
||||||
import { AccountInfoRequest, AccountInfoResponse } from './accountInfo'
|
import { AccountInfoRequest, AccountInfoResponse } from './accountInfo'
|
||||||
import { AccountLinesRequest, AccountLinesResponse } from './accountLines'
|
import { AccountLinesRequest, AccountLinesResponse } from './accountLines'
|
||||||
|
import {
|
||||||
|
AccountNamespaceRequest,
|
||||||
|
AccountNamespaceResponse,
|
||||||
|
} from './accountNamespace'
|
||||||
import { AccountNFTsRequest, AccountNFTsResponse } from './accountNFTs'
|
import { AccountNFTsRequest, AccountNFTsResponse } from './accountNFTs'
|
||||||
import { AccountObjectsRequest, AccountObjectsResponse } from './accountObjects'
|
import { AccountObjectsRequest, AccountObjectsResponse } from './accountObjects'
|
||||||
import {
|
import {
|
||||||
@@ -83,6 +87,7 @@ type Request =
|
|||||||
| AccountCurrenciesRequest
|
| AccountCurrenciesRequest
|
||||||
| AccountInfoRequest
|
| AccountInfoRequest
|
||||||
| AccountLinesRequest
|
| AccountLinesRequest
|
||||||
|
| AccountNamespaceRequest
|
||||||
| AccountNFTsRequest
|
| AccountNFTsRequest
|
||||||
| AccountObjectsRequest
|
| AccountObjectsRequest
|
||||||
| AccountOffersRequest
|
| AccountOffersRequest
|
||||||
@@ -133,6 +138,7 @@ type Response =
|
|||||||
| AccountCurrenciesResponse
|
| AccountCurrenciesResponse
|
||||||
| AccountInfoResponse
|
| AccountInfoResponse
|
||||||
| AccountLinesResponse
|
| AccountLinesResponse
|
||||||
|
| AccountNamespaceResponse
|
||||||
| AccountNFTsResponse
|
| AccountNFTsResponse
|
||||||
| AccountObjectsResponse
|
| AccountObjectsResponse
|
||||||
| AccountOffersResponse
|
| AccountOffersResponse
|
||||||
|
|||||||
@@ -11,17 +11,16 @@ export interface HookExecution {
|
|||||||
HookReturnCode: string
|
HookReturnCode: string
|
||||||
HookReturnString: string
|
HookReturnString: string
|
||||||
HookStateChangeCount: number
|
HookStateChangeCount: number
|
||||||
|
Flags: number
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface HookEmission {
|
export interface HookEmission {
|
||||||
HookEmission: {
|
HookEmission: {
|
||||||
EmitGeneration: number
|
EmittedTxnID: string
|
||||||
EmitBurden: string
|
HookAccount: string
|
||||||
EmitParentTxnID: string
|
HookHash: string
|
||||||
EmitNonce: string
|
EmitNonce: string
|
||||||
EmitCallback: string
|
|
||||||
EmitHookHash: string
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user