> For the complete documentation index, see [llms.txt](https://docs.aboutcircles.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.aboutcircles.com/circles-sdk/circles-avatars/personal-human-avatars/handle-profile-of-an-avatar.md).

# Fetching profile of an human avatar

## Get a profile for the avatar

This function fetches the current profile associated with the avatar. If no profile exists, it will return `undefined`.

```typescript
const profile = await inviteeAvatar.profile.get();
if (profile) {
  console.log(profile.name, profile.description);
}
```

## Update profile of the avatar

This function pins JSON to the Profiles service and updates the metadata digest on-chain. Returns the new CID.

```typescript
import type { Profile } from '@aboutcircles/sdk-types';

const newProfile: Profile = {
  name: 'Avatar Name',
  description: 'Updated description for the avatar.',
  avatarUrl: 'ipfs://QmYourImageCIDHere', // optional
};

try {
  const newCid = await inviteeAvatar.profile.update(newProfile);
  console.log('Profile updated. New CID:', newCid);
} catch (err) {
  console.error('Error updating profile:', err);
}
```

If you already have your CID, you can use the function below to update the on-chain pointer:

```ts
const cid = 'QmYourIPFSCIDHere';

try {
  const receipt = await inviteeAvatar.profile.updateMetadata(cid);
  console.log('Metadata updated, tx:', receipt.hash);
} catch (err) {
  console.error('Error updating metadata:', err);
}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.aboutcircles.com/circles-sdk/circles-avatars/personal-human-avatars/handle-profile-of-an-avatar.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
