ソースを参照

add Curl to DAS API (#48)

* cleanup case

* split pages add curl

* Update index.js

Fixed duplicate url/nav link

---------

Co-authored-by: Tony Boyle <81017245+tonyboylehub@users.noreply.github.com>
MarkSackerberg 1 年間 前
コミット
e2656da81d

+ 17 - 7
src/components/products/das-api/index.js

@@ -8,10 +8,10 @@ import { Hero } from './Hero'
 import { Logo } from './Logo'
 import { Logo } from './Logo'
 
 
 export const das = {
 export const das = {
-  name: 'DAS Api',
-  headline: 'DAS API',
+  name: 'DAS API',
+  headline: 'Fetch Digital Asset Data',
   description:
   description:
-    'A DAS API Client for access the Digital Asset Standard',
+    'A DAS API Client to access Digital Asset data on chain',
   path: 'das-api',
   path: 'das-api',
   logo: Logo,
   logo: Logo,
   github: 'https://github.com/metaplex-foundation/digital-asset-standard-api',
   github: 'https://github.com/metaplex-foundation/digital-asset-standard-api',
@@ -26,10 +26,20 @@ export const das = {
           title: 'Introduction',
           title: 'Introduction',
           links: [
           links: [
             { title: 'Overview', href: '/das-api' },
             { title: 'Overview', href: '/das-api' },
-            { title: 'Getting started', href: '/das-api/getting-started' },
-           
-            { title: 'Methods', href: '/das-api/methods' },
-
+            { title: 'Getting started', href: '/das-api/getting-started' },     
+          ],
+        },
+        {
+          title: 'Methods',
+          links: [
+            { title: 'Method Overview', href: '/das-api/methods' },
+            { title: 'Get Asset', href: '/das-api/methods/get-asset' },
+            { title: 'Get Asset Proof', href: '/das-api/methods/get-asset-proof' },
+            { title: 'Get Asset By Authority', href: '/das-api/methods/get-asset-by-authority' },
+            { title: 'Get Asset By Creator', href: '/das-api/methods/get-asset-by-creator' },
+            { title: 'Get Asset By Group', href: '/das-api/methods/get-asset-by-group' },
+            { title: 'Get Asset By Owner', href: '/das-api/methods/get-asset-by-owner' },
+            { title: 'Search Asset', href: '/das-api/methods/search-assets' },
           ],
           ],
         },
         },
       ],
       ],

+ 4 - 10
src/pages/das-api/getting-started.md

@@ -1,12 +1,12 @@
 ---
 ---
 title: Getting Started
 title: Getting Started
-metaTitle: DAS Api - Getting Started
-description: Installation and setup of the Metaplex DAS Api client.
+metaTitle: DAS API - Getting Started
+description: Installation and setup of the Metaplex DAS API client.
 ---
 ---
 
 
 The `@metaplex-foundation/digital-asset-standard-api` package can be use to interact with Metaplex DAS API:
 The `@metaplex-foundation/digital-asset-standard-api` package can be use to interact with Metaplex DAS API:
 
 
-The DAS Api client is a Umi plugin so you will have to install Umi in conjunction with the DAS Api client.
+The DAS API client is a Umi plugin so you will have to install Umi in conjunction with the DAS API client.
 
 
 You can install the plugin from the location below.
 You can install the plugin from the location below.
 
 
@@ -22,12 +22,6 @@ import { dasApi } from "@metaplex-foundation/digital-asset-standard-api"
 const umi = createUmi("exampleDasProvider.com").use(dasApi());
 const umi = createUmi("exampleDasProvider.com").use(dasApi());
 ```
 ```
 
 
-The plugin can be used with any RPC that supports the Metaplex DAS API specification – the following RPCs (in alphabetical order) support the specification:
-
-- [Helius](https://www.helius.dev/)
-- [Hello Moon](https://www.hellomoon.io/developers)
-- [QuickNode](https://www.quicknode.com/)
-- [Shyft](https://shyft.to/)
-- [Triton](https://triton.one/)
+The plugin can be used with any RPC that supports the Metaplex DAS API specification – RPCs that support the specification can be found on the [RPC Providers page](/rpc-providers).
 
 
 Note You might need to contact your RPC provider to "enable" the DAS API on your endpoint.
 Note You might need to contact your RPC provider to "enable" the DAS API on your endpoint.

+ 4 - 4
src/pages/das-api/index.md

@@ -1,7 +1,7 @@
 ---
 ---
-title: DAS Api
-metaTitle: DAS Api - Overview
-description: A DAS Api client used to access the Metaplex Digital Asset Standard.
+title: DAS API
+metaTitle: DAS API - Overview
+description: A DAS API client used to access the Metaplex Digital Asset Standard.
 ---
 ---
 
 
 The state data of uncompressed NFTs is all stored in on-chain accounts. This is expensive at scale. Compressed NFTs save space by encoding the state data into an on-chain Merkle tree. The detailed account data is not stored on-chain, but in data stores managed by RPC providers. The Metaplex Digital Asset Standard (DAS) API represents a unified interface for interacting with digital assets on Solana, supporting both standard (Token Metadata) and compressed (Bubblegum) assets.
 The state data of uncompressed NFTs is all stored in on-chain accounts. This is expensive at scale. Compressed NFTs save space by encoding the state data into an on-chain Merkle tree. The detailed account data is not stored on-chain, but in data stores managed by RPC providers. The Metaplex Digital Asset Standard (DAS) API represents a unified interface for interacting with digital assets on Solana, supporting both standard (Token Metadata) and compressed (Bubblegum) assets.
@@ -12,6 +12,6 @@ The API defines a set of methods that RPCs implement in order to provide asset d
 
 
 {% quick-link title="Getting Started" icon="InboxArrowDown" href="/das-api/getting-started" description="Find the language or library of your choice and get started essentials programs." /%}
 {% quick-link title="Getting Started" icon="InboxArrowDown" href="/das-api/getting-started" description="Find the language or library of your choice and get started essentials programs." /%}
 
 
-{% quick-link title="Methods" icon="CodeBracketSquare" href="/das-api/methods" description="DAS Api methods for fetching data." /%}
+{% quick-link title="Methods" icon="CodeBracketSquare" href="/das-api/methods" description="DAS API methods for fetching data." /%}
 
 
 {% /quick-links %}
 {% /quick-links %}

+ 0 - 218
src/pages/das-api/methods.md

@@ -1,218 +0,0 @@
----
-title: Methods
-metaTitle: DAS Api - Methods
-description: Callable Api Methods for the Metaplex DAS Api client.
----
-
-The DAS Api supports the following methods;
-
-## `getAsset`
-
-#### Parameters
-| Name            | Required | Description                                |
-| --------------- | :------: | ------------------------------------------ |
-| `id`            |    ✅    | The id of the asset.                       |
-
-```js
-import { publicKey } from '@metaplex-foundation/umi';
-import { createUmi } from '@metaplex-foundation/umi-bundle-defaults';
-import { dasApi } from '@metaplex-foundation/digital-asset-standard-api';
-
-const umi = createUmi('<ENDPOINT>').use(dasApi());
-const assetId = publicKey('8TrvJBRa6Pzb9BDadqroHhWTHxaxK8Ws8r91oZ2jxaVV');
-
-const asset = await umi.rpc.getAsset(assetId);
-console.log(asset);
-```
-
-## `getAssetProof`
-
-#### Parameters
-| Name            | Required | Description                                |
-| --------------- | :------: | ------------------------------------------ |
-| `id`            |    ✅    | The id of the asset.                       |
-
-```js
-import { publicKey } from '@metaplex-foundation/umi';
-import { createUmi } from '@metaplex-foundation/umi-bundle-defaults';
-import { dasApi } from '@metaplex-foundation/digital-asset-standard-api';
-
-const umi = createUmi('<ENDPOINT>').use(dasApi());
-const assetId = publicKey('Ez6ezCMkRaUkWS5v6WVcP7uuCWiKadr3W2dHFkoZmteW');
-
-const proof = await umi.rpc.getAssetProof(assetId);
-console.log(proof);
-```
-
-## getAssetsByAuthority
-
-#### Parameters
-| Name               | Required | Description                                |
-| ------------------ | :------: | ------------------------------------------ |
-| `authorityAddress` |    ✅    | The address of the authority of the assets.|
-| `sortBy`           |          | Sorting criteria. This is specified as an object `{ sortBy: <value>, sortDirection: <value> }`, where `sortBy` is one of `["created", "updated", "recentAction", "none"]` and `sortDirection` is one of `["asc", "desc"]`     |
-| `limit`            |          | The maximum number of assets to retrieve.  |
-| `page`             |          | The index of the "page" to retrieve.       |
-| `before`           |          | Retrieve assets before the specified ID.   |
-| `after`            |          | Retrieve assets after the specified ID.    |
-
-
-```js
-import { publicKey } from '@metaplex-foundation/umi';
-import { createUmi } from '@metaplex-foundation/umi-bundle-defaults';
-import { dasApi } from '@metaplex-foundation/digital-asset-standard-api';
-
-const umi = createUmi('<ENDPOINT>').use(dasApi());
-const authority = publicKey('mRdta4rc2RtsxEUDYuvKLamMZAdW6qHcwuq866Skxxv');
-
-const assets = await umi.rpc.getAssetsByAuthority(
-  { 
-    authority,
-    sortBy, // optional
-    limit, // optional
-    page, // optional
-    before, // optional
-    after, // optional
-  }
-);
-console.log(assets.items.length > 0);
-```
-
-
-## `getAssetsByCreator`
-
-#### Parameters
-
-| Name               | Required | Description                                |
-| ------------------ | :------: | ------------------------------------------ |
-| `creatorAddress`   |    ✅    | The address of the creator of the assets.  |
-| `onlyVerified`     |          | Indicates whether to retrieve only verified assets or not.  |
-| `sortBy`           |          | Sorting criteria. This is specified as an object `{ sortBy: <value>, sortDirection: <value> }`, where `sortBy` is one of `["created", "updated", "recentAction", "none"]` and `sortDirection` is one of `["asc", "desc"]`     |
-| `limit`            |          | The maximum number of assets to retrieve.  |
-| `page`             |          | The index of the "page" to retrieve.       |
-| `before`           |          | Retrieve assets before the specified ID.   |
-| `after`            |          | Retrieve assets after the specified ID.    |
-
-
-```ts
-import { publicKey } from '@metaplex-foundation/umi';
-import { createUmi } from '@metaplex-foundation/umi-bundle-defaults';
-import { dasApi } from '@metaplex-foundation/digital-asset-standard-api';
-
-const umi = createUmi('<ENDPOINT>').use(dasApi());
-const creator = publicKey('D3XrkNZz6wx6cofot7Zohsf2KSsu2ArngNk8VqU9cTY3');
-
-const assets = await umi.rpc.getAssetsByCreator({
-    creator,
-    onlyVerified: false,
-    limit: 10,
-});
-console.log(assets.items.length > 0);
-```
-
-## `getAssetsByGroup`
-
-#### Parameters
-| Name               | Required | Description                                |
-| ------------------ | :------: | ------------------------------------------ |
-| `groupKey`         |    ✅    | The key of the group (e.g., `"collection"`).  |
-| `groupValue`       |    ✅    | The value of the group.  |
-| `sortBy`           |          | Sorting criteria. This is specified as an object `{ sortBy: <value>, sortDirection: <value> }`, where `sortBy` is one of `["created", "updated", "recentAction", "none"]` and `sortDirection` is one of `["asc", "desc"]`     |
-| `limit`            |          | The maximum number of assets to retrieve.  |
-| `page`             |          | The index of the "page" to retrieve.       |
-| `before`           |          | Retrieve assets before the specified ID.   |
-| `after`            |          | Retrieve assets after the specified ID.    |
-
-
-
-```ts
-import { publicKey } from '@metaplex-foundation/umi';
-import { createUmi } from '@metaplex-foundation/umi-bundle-defaults';
-import { dasApi } from '@metaplex-foundation/digital-asset-standard-api';
-
-const umi = createUmi('<ENDPOINT>').use(dasApi());
-
-const assets = await umi.rpc.getAssetsByGroup({
-    groupKey: 'collection',
-    groupValue: 'J2ZfLdQsaZ3GCmbucJef3cPnPwGcgjDW1SSYtMdq3L9p',
-});
-console.log(assets.items.length > 0);
-```
-
-
-## `getAssetsByOwner`
-
-#### Parameters
-| Name               | Required | Description                                |
-| ------------------ | :------: | ------------------------------------------ |
-| `ownerAddress`     |    ✅    | The address of the owner of the assets.    |
-| `sortBy`           |          | Sorting criteria. This is specified as an object `{ sortBy: <value>, sortDirection: <value> }`, where `sortBy` is one of `["created", "updated", "recentAction", "none"]` and `sortDirection` is one of `["asc", "desc"]`     |
-| `limit`            |          | The maximum number of assets to retrieve.  |
-| `page`             |          | The index of the "page" to retrieve.       |
-| `before`           |          | Retrieve assets before the specified ID.   |
-| `after`            |          | Retrieve assets after the specified ID.    |
-
-
-```typescript
-import { publicKey } from '@metaplex-foundation/umi';
-import { createUmi } from '@metaplex-foundation/umi-bundle-defaults';
-import { dasApi } from '@metaplex-foundation/digital-asset-standard-api';
-
-const umi = createUmi('<ENDPOINT>').use(dasApi());
-const owner = publicKey('N4f6zftYsuu4yT7icsjLwh4i6pB1zvvKbseHj2NmSQw');
-
-const assets = await umi.rpc.getAssetsByOwner({
-    owner,
-    limit: 10
-});
-console.log(assets.items.length > 0);
-```
-
-
-
-## `searchAssets`
-
-#### Parameters
-| Name                | Required | Description                                |
-| ------------------- | :------: | ------------------------------------------ |
-| `negate`            |          | Indicates whether the search criteria should be inverted or not.  |
-| `conditionType`     |          | Indicates whether to retrieve all (`"all"`) or any (`"any"`) asset that matches the search criteria.  |
-| `interface`         |          | The interface value (one of `["V1_NFT", "V1_PRINT" "LEGACY_NFT", "V2_NFT", "FungibleAsset", "Custom", "Identity", "Executable"]`).  |
-| `ownerAddress`      |          | The address of the owner.  |
-| `ownerType`         |          | Type of ownership `["single", "token"]`.  |
-| `creatorAddress`    |          | The address of the creator.  |
-| `creatorVerified`   |          | Indicates whether the creator must be verified or not.  |
-| `authorityAddress`  |          | The address of the authority.  |
-| `grouping`          |          | The grouping `["key", "value"]` pair.  |
-| `delegateAddress`   |          | The address of the delegate.  |
-| `frozen`            |          | Indicates whether the asset is frozen or not.  |
-| `supply`            |          | The supply of the asset.  |
-| `supplyMint`        |          | The address of the supply mint.  |
-| `compressed`        |          | Indicates whether the asset is compressed or not.  |
-| `compressible`      |          | Indicates whether the asset is compressible or not.  |
-| `royaltyTargetType` |          | Type of royalty `["creators", "fanout", "single"]`.  |
-| `royaltyTarget`     |          | The target address for royalties.  |
-| `royaltyAmount`     |          | The royalties amount.  |
-| `burnt`             |          | Indicates whether the asset is burnt or not.  |
-| `sortBy`            |          | Sorting criteria. This is specified as an object `{ sortBy: <value>, sortDirection: <value> }`, where `sortBy` is one of `["created", "updated", "recentAction", "none"]` and `sortDirection` is one of `["asc", "desc"]`.     |
-| `limit`             |          | The maximum number of assets to retrieve.  |
-| `page`              |          | The index of the "page" to retrieve.       |
-| `before`            |          | Retrieve assets before the specified ID.   |
-| `after`             |          | Retrieve assets after the specified ID.    |
-| `jsonUri`           |          | The value for the JSON URI.  |
-
-
-```ts
-import { publicKey } from '@metaplex-foundation/umi';
-import { createUmi } from '@metaplex-foundation/umi-bundle-defaults';
-import { dasApi } from '@metaplex-foundation/digital-asset-standard-api';
-
-const umi = createUmi('<ENDPOINT>').use(dasApi());
-
-const assets = await umi.rpc.searchAssets({
-    owner: publicKey('N4f6zftYsuu4yT7icsjLwh4i6pB1zvvKbseHj2NmSQw'),
-    jsonUri: 'https://arweave.net/c9aGs5fOk7gD4wWnSvmzeqgtfxAGRgtI1jYzvl8-IVs/chiaki-violet-azure-common.json',
-});
-console.log(assets.items.length == 1);
-```
-

+ 67 - 0
src/pages/das-api/methods/get-asset-by-authority.md

@@ -0,0 +1,67 @@
+---
+title: Get Asset By Authority
+metaTitle: DAS API - Get Asset By Authority
+description: Returns the list of assets given an authority address
+---
+
+Returns the list of assets given an authority address.
+
+## Parameters
+
+| Name               | Required | Description                                |
+| ------------------ | :------: | ------------------------------------------ |
+| `authorityAddress` |    ✅    | The address of the authority of the assets.|
+| `sortBy`           |          | Sorting criteria. This is specified as an object `{ sortBy: <value>, sortDirection: <value> }`, where `sortBy` is one of `["created", "updated", "recentAction", "none"]` and `sortDirection` is one of `["asc", "desc"]`     |
+| `limit`            |          | The maximum number of assets to retrieve.  |
+| `page`             |          | The index of the "page" to retrieve.       |
+| `before`           |          | Retrieve assets before the specified ID.   |
+| `after`            |          | Retrieve assets after the specified ID.    |
+
+
+## Example
+
+{% dialect-switcher title="getAssetByAuthority Example" %}
+{% dialect title="JavaScript" id="js" %}
+{% totem %}
+
+```js
+import { publicKey } from '@metaplex-foundation/umi';
+import { createUmi } from '@metaplex-foundation/umi-bundle-defaults';
+import { dasApi } from '@metaplex-foundation/digital-asset-standard-api';
+
+const umi = createUmi('<ENDPOINT>').use(dasApi());
+const authority = publicKey('mRdta4rc2RtsxEUDYuvKLamMZAdW6qHcwuq866Skxxv');
+
+const assets = await umi.rpc.getAssetsByAuthority(
+  { 
+    authority,
+    sortBy, // optional
+    limit, // optional
+    page, // optional
+    before, // optional
+    after, // optional
+  }
+);
+console.log(assets.items.length > 0);
+```
+
+{% /totem %}
+{% /dialect %}
+{% dialect title="cURL" id="curl" %}
+{% totem %}
+
+```sh
+curl --request POST --url "<ENDPOINT>" --header 'Content-Type: application/json' --data '{
+    "jsonrpc": "2.0",
+    "method": "getAssetsByAuthority",
+    "params": {
+        "authorityAddress": "mRdta4rc2RtsxEUDYuvKLamMZAdW6qHcwuq866Skxxv",
+        "page": 1
+    },
+    "id": 0
+}'
+```
+
+{% /totem %}
+{% /dialect %}
+{% /dialect-switcher %}

+ 69 - 0
src/pages/das-api/methods/get-asset-by-creator.md

@@ -0,0 +1,69 @@
+---
+title: Get Asset By Creator
+metaTitle: DAS API - Get Asset By Creator
+description: Returns the list of assets given an authority address
+---
+
+Return the list of assets given a creator address.
+
+{% callout %}
+We recommend to fetch data with `onlyVerified: true` to make sure the asset actually belongs to that creator.
+{% /callout %}
+
+## Parameters
+
+| Name               | Required | Description                                |
+| ------------------ | :------: | ------------------------------------------ |
+| `creatorAddress`   |    ✅    | The address of the creator of the assets.  |
+| `onlyVerified`     |          | Indicates whether to retrieve only verified assets or not.  |
+| `sortBy`           |          | Sorting criteria. This is specified as an object `{ sortBy: <value>, sortDirection: <value> }`, where `sortBy` is one of `["created", "updated", "recentAction", "none"]` and `sortDirection` is one of `["asc", "desc"]`     |
+| `limit`            |          | The maximum number of assets to retrieve.  |
+| `page`             |          | The index of the "page" to retrieve.       |
+| `before`           |          | Retrieve assets before the specified ID.   |
+| `after`            |          | Retrieve assets after the specified ID.    |
+
+
+## Example
+
+{% dialect-switcher title="getAssetByCreator Example" %}
+{% dialect title="JavaScript" id="js" %}
+{% totem %}
+
+```js
+import { publicKey } from '@metaplex-foundation/umi';
+import { createUmi } from '@metaplex-foundation/umi-bundle-defaults';
+import { dasApi } from '@metaplex-foundation/digital-asset-standard-api';
+
+const umi = createUmi('<ENDPOINT>').use(dasApi());
+const creator = publicKey('D3XrkNZz6wx6cofot7Zohsf2KSsu2ArngNk8VqU9cTY3');
+
+const assets = await umi.rpc.getAssetsByCreator({
+    creator,
+    onlyVerified: true,
+    limit: 10,
+});
+console.log(assets.items.length > 0);
+```
+
+{% /totem %}
+{% /dialect %}
+{% dialect title="cURL" id="curl" %}
+{% totem %}
+
+```sh
+curl --request POST --url "<ENDPOINT>" --header 'Content-Type: application/json' --data '{
+    "jsonrpc": "2.0",
+    "method": "getAssetsByCreator",
+    "params": {
+        "creatorAddress": "D3XrkNZz6wx6cofot7Zohsf2KSsu2ArngNk8VqU9cTY3",
+        "onlyVerified": false,
+        "limit": 10,
+        "page": 1
+    },
+    "id": 0
+}'
+```
+
+{% /totem %}
+{% /dialect %}
+{% /dialect-switcher %}

+ 61 - 0
src/pages/das-api/methods/get-asset-by-group.md

@@ -0,0 +1,61 @@
+---
+title: Get Asset By Group
+metaTitle: DAS API - Get Asset By Group
+description: Return the list of assets given a group (key, value) pair
+---
+
+Return the list of assets given a group (key, value) pair. For example this can be used to get all assets in a collection.
+
+## Parameters
+
+| Name               | Required | Description                                |
+| ------------------ | :------: | ------------------------------------------ |
+| `groupKey`         |    ✅    | The key of the group (e.g., `"collection"`).  |
+| `groupValue`       |    ✅    | The value of the group.  |
+| `sortBy`           |          | Sorting criteria. This is specified as an object `{ sortBy: <value>, sortDirection: <value> }`, where `sortBy` is one of `["created", "updated", "recentAction", "none"]` and `sortDirection` is one of `["asc", "desc"]`     |
+| `limit`            |          | The maximum number of assets to retrieve.  |
+| `page`             |          | The index of the "page" to retrieve.       |
+| `before`           |          | Retrieve assets before the specified ID.   |
+| `after`            |          | Retrieve assets after the specified ID.    |
+
+## Example
+
+{% dialect-switcher title="getAssetByGroup Example" %}
+{% dialect title="JavaScript" id="js" %}
+{% totem %}
+
+```js
+import { publicKey } from '@metaplex-foundation/umi';
+import { createUmi } from '@metaplex-foundation/umi-bundle-defaults';
+import { dasApi } from '@metaplex-foundation/digital-asset-standard-api';
+
+const umi = createUmi('<ENDPOINT>').use(dasApi());
+
+const assets = await umi.rpc.getAssetsByGroup({
+    groupKey: 'collection',
+    groupValue: 'J2ZfLdQsaZ3GCmbucJef3cPnPwGcgjDW1SSYtMdq3L9p',
+});
+console.log(assets.items.length > 0);
+```
+
+{% /totem %}
+{% /dialect %}
+{% dialect title="cURL" id="curl" %}
+{% totem %}
+
+```sh
+curl --request POST --url "<ENDPOINT>" --header 'Content-Type: application/json' --data '{
+    "jsonrpc": "2.0",
+    "method": "getAssetsByGroup",
+    "params": {
+        "groupKey": "collection",
+        "groupValue": "J2ZfLdQsaZ3GCmbucJef3cPnPwGcgjDW1SSYtMdq3L9p",
+        "page": 1
+    },
+    "id": 0
+}'
+```
+
+{% /totem %}
+{% /dialect %}
+{% /dialect-switcher %}

+ 61 - 0
src/pages/das-api/methods/get-asset-by-owner.md

@@ -0,0 +1,61 @@
+---
+title: Get Asset By Owner
+metaTitle: DAS API - Get Asset By Owner
+description: Return the list of assets given an owner address
+---
+
+Return the list of assets given an owner address.
+
+## Parameters
+
+| Name               | Required | Description                                |
+| ------------------ | :------: | ------------------------------------------ |
+| `ownerAddress`     |    ✅    | The address of the owner of the assets.    |
+| `sortBy`           |          | Sorting criteria. This is specified as an object `{ sortBy: <value>, sortDirection: <value> }`, where `sortBy` is one of `["created", "updated", "recentAction", "none"]` and `sortDirection` is one of `["asc", "desc"]`     |
+| `limit`            |          | The maximum number of assets to retrieve.  |
+| `page`             |          | The index of the "page" to retrieve.       |
+| `before`           |          | Retrieve assets before the specified ID.   |
+| `after`            |          | Retrieve assets after the specified ID.    |
+
+## Example
+
+{% dialect-switcher title="getAssetByOwner Example" %}
+{% dialect title="JavaScript" id="js" %}
+{% totem %}
+
+```js
+import { publicKey } from '@metaplex-foundation/umi';
+import { createUmi } from '@metaplex-foundation/umi-bundle-defaults';
+import { dasApi } from '@metaplex-foundation/digital-asset-standard-api';
+
+const umi = createUmi('<ENDPOINT>').use(dasApi());
+const owner = publicKey('N4f6zftYsuu4yT7icsjLwh4i6pB1zvvKbseHj2NmSQw');
+
+const assets = await umi.rpc.getAssetsByOwner({
+    owner,
+    limit: 10
+});
+console.log(assets.items.length > 0);
+```
+
+{% /totem %}
+{% /dialect %}
+{% dialect title="cURL" id="curl" %}
+{% totem %}
+
+```sh
+curl --request POST --url "<ENDPOINT>" --header 'Content-Type: application/json' --data '{
+    "jsonrpc": "2.0",
+    "method": "getAssetsByOwner",
+    "params": {
+        "ownerAddress": "N4f6zftYsuu4yT7icsjLwh4i6pB1zvvKbseHj2NmSQw",
+        "limit": 10,
+        "page": 1
+    },
+    "id": 0
+}'
+```
+
+{% /totem %}
+{% /dialect %}
+{% /dialect-switcher %}

+ 51 - 0
src/pages/das-api/methods/get-asset-proof.md

@@ -0,0 +1,51 @@
+---
+title: Get Asset Proof
+metaTitle: DAS API - Get Asset Proof
+description: Returns the merkle tree proof information for a compressed asset
+---
+
+Returns the merkle tree proof information for a compressed asset.
+
+## Parameters
+
+| Name            | Required | Description                                |
+| --------------- | :------: | ------------------------------------------ |
+| `id`            |    ✅    | The id of the asset.                       |
+
+## Example
+
+{% dialect-switcher title="getAssetProof Example" %}
+{% dialect title="JavaScript" id="js" %}
+{% totem %}
+
+```js
+import { publicKey } from '@metaplex-foundation/umi';
+import { createUmi } from '@metaplex-foundation/umi-bundle-defaults';
+import { dasApi } from '@metaplex-foundation/digital-asset-standard-api';
+
+const umi = createUmi('<ENDPOINT>').use(dasApi());
+const assetId = publicKey('Ez6ezCMkRaUkWS5v6WVcP7uuCWiKadr3W2dHFkoZmteW');
+
+const proof = await umi.rpc.getAssetProof(assetId);
+console.log(proof);
+```
+
+{% /totem %}
+{% /dialect %}
+{% dialect title="cURL" id="curl" %}
+{% totem %}
+
+```sh
+curl --request POST --url "<ENDPOINT>" --header 'Content-Type: application/json' --data '{
+    "jsonrpc": "2.0",
+    "method": "getAssetProof",
+    "params": [
+      "Ez6ezCMkRaUkWS5v6WVcP7uuCWiKadr3W2dHFkoZmteW"
+    ],
+    "id": 0
+}'
+```
+
+{% /totem %}
+{% /dialect %}
+{% /dialect-switcher %}

+ 51 - 0
src/pages/das-api/methods/get-asset.md

@@ -0,0 +1,51 @@
+---
+title: Get Asset
+metaTitle: DAS API - Get Asset
+description: Returns the information of a compressed/standard asset
+---
+
+Returns the information of a compressed/standard asset including metadata and owner.
+
+## Parameters
+
+| Name            | Required | Description                                |
+| --------------- | :------: | ------------------------------------------ |
+| `id`            |    ✅    | The id of the asset.                       |
+
+## Example
+
+{% dialect-switcher title="getAsset Example" %}
+{% dialect title="JavaScript" id="js" %}
+{% totem %}
+
+```js
+import { publicKey } from '@metaplex-foundation/umi';
+import { createUmi } from '@metaplex-foundation/umi-bundle-defaults';
+import { dasApi } from '@metaplex-foundation/digital-asset-standard-api';
+
+const umi = createUmi('<ENDPOINT>').use(dasApi());
+const assetId = publicKey('8TrvJBRa6Pzb9BDadqroHhWTHxaxK8Ws8r91oZ2jxaVV');
+
+const asset = await umi.rpc.getAsset(assetId);
+console.log(asset);
+```
+
+{% /totem %}
+{% /dialect %}
+{% dialect title="cURL" id="curl" %}
+{% totem %}
+
+```sh
+curl --request POST --url "<ENDPOINT>" --header 'Content-Type: application/json' --data '{
+    "jsonrpc": "2.0",
+    "method": "getAsset",
+    "params": [
+      "8vw7tdLGE3FBjaetsJrZAarwsbc8UESsegiLyvWXxs5A"
+    ],
+    "id": 0
+}'
+```
+
+{% /totem %}
+{% /dialect %}
+{% /dialect-switcher %}

+ 15 - 0
src/pages/das-api/methods/index.md

@@ -0,0 +1,15 @@
+---
+title: Methods
+metaTitle: DAS API - Methods
+description: Callable API Methods for the Metaplex DAS API client.
+---
+
+The DAS API supports the following methods:
+
+- [`getAsset`](/das-api-methods/get-asset): Returns the information of a compressed/standard asset including metadata and owner.
+- [`getAssetProof`](/das-api-methods/get-asset-proof): Returns the merkle tree proof information for a compressed asset.
+- [`getAssetsByAuthority`](/das-api-methods/get-asset-by-authority): Returns the list of assets given an authority address.
+- [`getAssetsByCreator`](/das-api-methods/get-asset-by-creator): Return the list of assets given a creator address.
+- [`getAssetsByGroup`](/das-api-methods/get-asset-by-creator): Return the list of assets given a group (key, value) pair. For example this can be used to get all assets in a collection.
+- [`getAssetsByOwner`](/das-api-methods/get-asset-by-owner): Return the list of assets given an owner address.
+- [`searchAssets`](/das-api-methods/search-assets): Return the list of assets given a search criteria.

+ 79 - 0
src/pages/das-api/methods/search-assets.md

@@ -0,0 +1,79 @@
+---
+title: Search Assets
+metaTitle: DAS API - Search Assets
+description: Return the list of assets given a search criteria
+---
+
+Return the list of assets given a search criteria.
+
+## Parameters
+
+| Name                | Required | Description                                |
+| ------------------- | :------: | ------------------------------------------ |
+| `negate`            |          | Indicates whether the search criteria should be inverted or not.  |
+| `conditionType`     |          | Indicates whether to retrieve all (`"all"`) or any (`"any"`) asset that matches the search criteria.  |
+| `interface`         |          | The interface value (one of `["V1_NFT", "V1_PRINT" "LEGACY_NFT", "V2_NFT", "FungibleAsset", "Custom", "Identity", "Executable"]`).  |
+| `ownerAddress`      |          | The address of the owner.  |
+| `ownerType`         |          | Type of ownership `["single", "token"]`.  |
+| `creatorAddress`    |          | The address of the creator.  |
+| `creatorVerified`   |          | Indicates whether the creator must be verified or not.  |
+| `authorityAddress`  |          | The address of the authority.  |
+| `grouping`          |          | The grouping `["key", "value"]` pair.  |
+| `delegateAddress`   |          | The address of the delegate.  |
+| `frozen`            |          | Indicates whether the asset is frozen or not.  |
+| `supply`            |          | The supply of the asset.  |
+| `supplyMint`        |          | The address of the supply mint.  |
+| `compressed`        |          | Indicates whether the asset is compressed or not.  |
+| `compressible`      |          | Indicates whether the asset is compressible or not.  |
+| `royaltyTargetType` |          | Type of royalty `["creators", "fanout", "single"]`.  |
+| `royaltyTarget`     |          | The target address for royalties.  |
+| `royaltyAmount`     |          | The royalties amount.  |
+| `burnt`             |          | Indicates whether the asset is burnt or not.  |
+| `sortBy`            |          | Sorting criteria. This is specified as an object `{ sortBy: <value>, sortDirection: <value> }`, where `sortBy` is one of `["created", "updated", "recentAction", "none"]` and `sortDirection` is one of `["asc", "desc"]`.     |
+| `limit`             |          | The maximum number of assets to retrieve.  |
+| `page`              |          | The index of the "page" to retrieve.       |
+| `before`            |          | Retrieve assets before the specified ID.   |
+| `after`             |          | Retrieve assets after the specified ID.    |
+| `jsonUri`           |          | The value for the JSON URI.  |
+
+## Example
+
+{% dialect-switcher title="getAssetByOwner Example" %}
+{% dialect title="JavaScript" id="js" %}
+{% totem %}
+
+```js
+import { publicKey } from '@metaplex-foundation/umi';
+import { createUmi } from '@metaplex-foundation/umi-bundle-defaults';
+import { dasApi } from '@metaplex-foundation/digital-asset-standard-api';
+
+const umi = createUmi('<ENDPOINT>').use(dasApi());
+
+const assets = await umi.rpc.searchAssets({
+    owner: publicKey('N4f6zftYsuu4yT7icsjLwh4i6pB1zvvKbseHj2NmSQw'),
+    jsonUri: 'https://arweave.net/c9aGs5fOk7gD4wWnSvmzeqgtfxAGRgtI1jYzvl8-IVs/chiaki-violet-azure-common.json',
+});
+console.log(assets.items.length == 1);
+```
+
+{% /totem %}
+{% /dialect %}
+{% dialect title="cURL" id="curl" %}
+{% totem %}
+
+```sh
+curl --request POST --url "<ENDPOINT>" --header 'Content-Type: application/json' --data '{
+    "jsonrpc": "2.0",
+    "method": "searchAssets",
+    "params": {
+        "ownerAddress": "N4f6zftYsuu4yT7icsjLwh4i6pB1zvvKbseHj2NmSQw",
+        "jsonUri": "https://arweave.net/c9aGs5fOk7gD4wWnSvmzeqgtfxAGRgtI1jYzvl8-IVs/chiaki-violet-azure-common.json",
+        "page": 1
+    },
+    "id": 0
+}'
+```
+
+{% /totem %}
+{% /dialect %}
+{% /dialect-switcher %}