Reset agent avatar
Reset agent avatar: resetAgentProfileAvatar in the TypeScript, Python, Rust and Go clients.
DELETE /v1/projects/{projectId}/agent-profile/avatar
Replaces the selected project's agent avatar with the project's default avatar, a generated planet image derived from the project ID, and returns the updated agent profile. The reset does not restore an earlier avatar: a custom avatar it replaces is discarded and must be uploaded and committed again to use it. When the default avatar is already in use, the profile is returned unchanged. This does not change the account's personal profile picture. Supply the required Idempotency-Key header.
photon.projects.agentProfile.resetAvatar(input: ResetAgentProfileAvatarInput, options?: RequestOptions): Promise<ResetAgentProfileAvatarOutput>photon.projects.agent_profile.reset_avatar(input: ResetAgentProfileAvatarInput, *, options: RequestOptions | None = None) -> models.AgentProfileclient.reset_agent_profile_avatar(idempotency_key: String, project_id: String).await -> Result<ResponseValue<types::AgentProfile>, Error<ResetAgentProfileAvatarError>>client.Projects.AgentProfile.ResetAvatar(ctx context.Context, params *ResetAgentProfileAvatarParams, opts ...RequestOption) (*AgentProfile, error)import { Photon } from "@photon-ai/api";
const photon = new Photon({
headers: { Authorization: `Bearer ${process.env.PHOTON_API_TOKEN}` },
});
const result = await photon.projects.agentProfile.resetAvatar({
path: {
projectId: "projectId",
},
headers: {
idempotencyKey: "idempotencyKey",
},
});import os
from photon_api import Photon
from photon_api.rpc_generated import ResetAgentProfileAvatarInput
photon = Photon(headers={"Authorization": f"Bearer {os.environ['PHOTON_API_TOKEN']}"})
result = photon.projects.agent_profile.reset_avatar(
ResetAgentProfileAvatarInput.model_validate({
"path": {
"projectId": "projectId",
},
"headers": {
"Idempotency-Key": "idempotencyKey",
},
})
)use photon_ai_api::{Credential, PhotonClientBuilder, SecretString};
let token = std::env::var("PHOTON_API_TOKEN")?;
let client = PhotonClientBuilder::new()
.credential("accountServiceKey", Credential::Bearer(SecretString::from(token)))
.build()?;
let result = client
.reset_agent_profile_avatar("idempotencyKey".to_owned(), "projectId".to_owned())
.await
.map_err(|error| format!("{error:?}"))?
.into_inner();import (
"context"
"os"
photonapi "github.com/photon-hq/api/packages/go"
)
ctx := context.Background()
client := photonapi.NewClient(photonapi.WithAPIKey(os.Getenv("PHOTON_API_TOKEN")))
result, err := client.Projects.AgentProfile.ResetAvatar(ctx, &photonapi.ResetAgentProfileAvatarParams{
IdempotencyKey: "idempotencyKey",
ProjectID: "projectId",
})
if err != nil {
return err
}
_ = result{
"avatarUrl": "https://example.com",
"firstName": "string",
"lastName": null
}Parameters
Selects the API contract date. Without it, the request is served as 2026-07-01.
Identifies one logical mutation across retries.
Returns
200 The agent profile with the project's default avatar. AgentProfile
Headers: Photon-Version. The raw response carries these headers; see Raw responses.