Delete Voice profile
Delete Voice profile: deleteVoiceProfile in the TypeScript, Python, Rust and Go clients.
DELETE /v1/projects/{id}/platforms/voice/profiles/{profileId}
Deletes an additional profile when expectedVersion matches. Assigned profiles require force=true, which atomically removes every stored override so affected lines follow the default. The default can never be deleted. Requires platforms:write bound to the path project.
photon.projects.platforms.deleteVoiceProfile(input: DeleteVoiceProfileInput, options?: RequestOptions): Promise<DeleteVoiceProfileOutput>photon.projects.platforms.delete_voice_profile(input: DeleteVoiceProfileInput, *, options: RequestOptions | None = None) -> Noneclient.delete_voice_profile(id: String, profile_id: String, expected_version: i64, params: Option<DeleteVoiceProfileParams>).await -> Result<ResponseValue<()>, Error<DeleteVoiceProfileError>>client.Projects.Platforms.DeleteVoiceProfile(ctx context.Context, params *DeleteVoiceProfileParams, opts ...RequestOption) errorimport { Photon } from "@photon-ai/api";
const photon = new Photon({
headers: { Authorization: `Bearer ${process.env.PHOTON_API_TOKEN}` },
});
await photon.projects.platforms.deleteVoiceProfile({
path: {
id: "id",
profileId: "profileId",
},
query: {
expectedVersion: 1,
},
});import os
from photon_api import Photon
from photon_api.rpc_generated import DeleteVoiceProfileInput
photon = Photon(headers={"Authorization": f"Bearer {os.environ['PHOTON_API_TOKEN']}"})
photon.projects.platforms.delete_voice_profile(
DeleteVoiceProfileInput.model_validate({
"path": {
"id": "id",
"profileId": "profileId",
},
"query": {
"expectedVersion": 1,
},
})
)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()?;
client
.delete_voice_profile("id".to_owned(), "profileId".to_owned(), 1, None)
.await
.map_err(|error| format!("{error:?}"))?;import (
"context"
"os"
photonapi "github.com/photon-hq/api/packages/go"
)
ctx := context.Background()
client := photonapi.NewClient(photonapi.WithAPIKey(os.Getenv("PHOTON_API_TOKEN")))
err := client.Projects.Platforms.DeleteVoiceProfile(ctx, &photonapi.DeleteVoiceProfileParams{
ID: "id",
ProfileID: "profileId",
ExpectedVersion: 1,
})
if err != nil {
return err
}Parameters
Selects the API contract date. Without it, the request is served as 2026-07-01.
Returns
204 The Voice profile was deleted. No body.
Headers: Photon-Version. The raw response carries these headers; see Raw responses.