Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use node API via API Gateway #302

Merged
merged 1 commit into from
Mar 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/api/general.ts
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ export class General {
* @param args.data Object that describes table item
* @param args.options.ledgerVersion The ledger version to query, if not provided it will get the latest version
*
* @example https://fullnode.devnet.aptoslabs.com/v1/accounts/0x1/resource/0x1::coin::CoinInfo%3C0x1::aptos_coin::AptosCoin%3E
* @example https://api.devnet.aptoslabs.com/v1/accounts/0x1/resource/0x1::coin::CoinInfo%3C0x1::aptos_coin::AptosCoin%3E
* {
* data.key_type = "address" // Move type of table key
* data.value_type = "u128" // Move type of table value
Expand Down
2 changes: 1 addition & 1 deletion src/api/transaction.ts
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ export class Transaction {
/**
* Gives an estimate of the gas unit price required to get a
* transaction on chain in a reasonable amount of time.
* For more information {@link https://fullnode.mainnet.aptoslabs.com/v1/spec#/operations/estimate_gas_price}
* For more information {@link https://api.mainnet.aptoslabs.com/v1/spec#/operations/estimate_gas_price}
*
* @returns Object holding the outputs of the estimate gas API
* @example
Expand Down
2 changes: 1 addition & 1 deletion src/types/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ export interface Client {
/**
* The API request type
*
* @param url - the url to make the request to, i.e https://fullnode.aptoslabs.devnet.com/v1
* @param url - the url to make the request to, i.e https://fullnode.devnet.aptoslabs.com/v1
* @param method - the request method "GET" | "POST"
* @param endpoint (optional) - the endpoint to make the request to, i.e transactions
* @param body (optional) - the body of the request
Expand Down
6 changes: 3 additions & 3 deletions src/utils/apiEndpoints.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ export const NetworkToIndexerAPI: Record<string, string> = {
};

export const NetworkToNodeAPI: Record<string, string> = {
mainnet: "https://fullnode.mainnet.aptoslabs.com/v1",
testnet: "https://fullnode.testnet.aptoslabs.com/v1",
devnet: "https://fullnode.devnet.aptoslabs.com/v1",
mainnet: "https://api.mainnet.aptoslabs.com/v1",
testnet: "https://api.testnet.aptoslabs.com/v1",
devnet: "https://api.devnet.aptoslabs.com/v1",
randomnet: "https://fullnode.random.aptoslabs.com/v1",
local: "http://127.0.0.1:8080/v1",
};
Expand Down
Loading