# Collections

### Collections[​](https://docs.x.immutable.com/docs/x/how-to-get-data#collections) <a href="#collections" id="collections"></a>

#### Get list of collections[​](https://docs.x.immutable.com/docs/x/how-to-get-data#get-list-of-collections) <a href="#get-list-of-collections" id="get-list-of-collections"></a>

The list of collections returned can be filtered by passing in parameters to this function.

* Typescript Core SDK

📚SDK REFERENCE

* <mark style="color:blue;">listCollections</mark>

#### Request[​](https://docs.x.immutable.com/docs/x/how-to-get-data#request-2) <a href="#request-2" id="request-2"></a>

Get a list of collections with "NFT" in the collection name or description:

```
const getListCollections = async (keyword: string) => {
  const response = await client.listCollections({
    keyword,
  });

  return response.result;
};

getListCollections('NFT')
  .then((result) => {
    console.log(result);
  })
  .catch((e) => {
    console.log(e);
  });
```

#### Example response[​](https://docs.x.immutable.com/docs/x/how-to-get-data#example-response-2) <a href="#example-response-2" id="example-response-2"></a>

```
{
  result: [
     {
      address: '0x61e506cec264d5b2705f10e5a934dc5313a56a6e', // Contract address of the collection
      name: 'The ARK NFTs',
      description: 'Find all the NFTs Created on the ARK Marketplace',
      icon_url: 'https://cloudflare-ipfs.com/ipfs/bafkreiadl5kmdwy4tum4tgny4avxedlif33x2awux35c75j4exnz5s7xjm',
      collection_image_url: '',
      project_id: 92,
      project_owner_address: '0x59bb6d1b896a9a139380bf2b8d828819f0cf1409',
      metadata_api_url: 'https://api.thearknft.io/v1/nft',
      created_at: '2022-09-28T12:01:20.479636Z',
      updated_at: '2022-09-28T13:35:07.59868Z'
    },
    // Other collections returned
    ...
  ],
  cursor: "eyJuYW1lIjoiSnVqdSBNaW50cyIsImFkZHJlc3MiOiIweDIzZGIwZTcyYmQ3NzM4ZGEwZDBhZmU3YmNjYjQxMDlmNWYwNWVkY2YiLCJwcm9qZWN0X2lkIjoyNCwiY3JlYXRlZF9hdCI6IjIwMjItMDktMjJUMjM6MTI6NTcuNjY0NDU2WiIsInVwZGF0ZWRfYXQiOiIyMDIyLTA5LTIyVDIzOjEyOjU3LjY2NDQ1NloifQ",
  // Remaining results
  remaining: 1
}
```

* Kotlin (JVM) Core SDK

📚SDK REFERENCE

* <mark style="color:blue;">listCollections</mark>

#### Request[​](https://docs.x.immutable.com/docs/x/how-to-get-data#request-3) <a href="#request-3" id="request-3"></a>

Get a list of collections ordered by name in ascending order:

```
val response = CollectionsApi().listCollections(
    pageSize = 20,
    orderBy = "name",
    direction = "asc"
)
```

* Swift Core SDK

📚SDK REFERENCE

* <mark style="color:blue;">listCollections</mark>

#### Request[​](https://docs.x.immutable.com/docs/x/how-to-get-data#request-4) <a href="#request-4" id="request-4"></a>

Get a list of collections ordered by name in ascending order:

```
let collections = try await CollectionsAPI.listCollections(
    pageSize: 20,
    orderBy: .name,
    direction: "asc"
)
```

* Golang Core SDK

📚SDK REFERENCE

* <mark style="color:blue;">ListCollections</mark>

* C# Core SDK

📚SDK REFERENCE

* <mark style="color:blue;">ListCollections</mark>

#### Get details about a collection[​](https://docs.x.immutable.com/docs/x/how-to-get-data#get-details-about-a-collection) <a href="#get-details-about-a-collection" id="get-details-about-a-collection"></a>

* Typescript Core SDK

📚SDK REFERENCE

* <mark style="color:blue;">getCollection</mark>

#### Request[​](https://docs.x.immutable.com/docs/x/how-to-get-data#request-5) <a href="#request-5" id="request-5"></a>

Get details of a collection at a given contract address:

```
const getCollection = async (address: string) => {
  const response = await client.getCollection({
    address,
  });

  return response;
};

getCollection('0x61e506cec264d5b2705f10e5a934dc5313a56a6e')
  .then((result) => {
    console.log(result);
  })
  .catch((e) => {
    console.log(e);
  });
```

#### Example response[​](https://docs.x.immutable.com/docs/x/how-to-get-data#example-response-3) <a href="#example-response-3" id="example-response-3"></a>

```
{
  address: '0x61e506cec264d5b2705f10e5a934dc5313a56a6e', // Contract address of the collection
  name: 'The ARK NFTs',
  description: 'Find all the NFTs Created on the ARK Marketplace',
  icon_url: 'https://cloudflare-ipfs.com/ipfs/bafkreiadl5kmdwy4tum4tgny4avxedlif33x2awux35c75j4exnz5s7xjm',
  collection_image_url: '',
  project_id: 92,
  project_owner_address: '0x59bb6d1b896a9a139380bf2b8d828819f0cf1409',
  metadata_api_url: 'https://api.thearknft.io/v1/nft',
  created_at: '2022-09-28T12:01:20.479636Z',
  updated_at: '2022-09-28T13:35:07.59868Z'
}
```

* Kotlin (JVM) Core SDK

📚SDK REFERENCE

* <mark style="color:blue;">getCollection</mark>

* Swift Core SDK

📚SDK REFERENCE

* <mark style="color:blue;">getCollection</mark>

* Golang Core SDK

📚SDK REFERENCE

* <mark style="color:blue;">GetCollection</mark>

See <mark style="color:blue;">GetCollection example</mark> in our SDK repo.

* C# Core SDK

📚SDK REFERENCE

* <mark style="color:blue;">GetCollection</mark>
