> For the complete documentation index, see [llms.txt](https://ryan-44.gitbook.io/portrait/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://ryan-44.gitbook.io/portrait/portrait-sdk/collective-portraits/read/getnamebytokenid.md).

# getNameByTokenId()

```typescript
/**
   * Get the name of the Collective Portrait for a given token ID.
   *
   * @remarks
   * The token ID is the unique identifier of the Collective Portrait. It is used to identify the Collective Portrait in the contract, as part of ERC-1155.
   *
   * @param {number} id - The token ID of the Collective Portrait that the user would like to get the name for.
   * @returns {CollectivePortraitName} - The name of the Collective Portrait.
   * @beta
   * @async
   */
  getNameByTokenId(id: number): CollectivePortraitName {
    return this.portrait.portraitCollectiveContract.getNameByTokenId(id);
  }

```
