Delete version
You can delete a prompt version by sending a DELETE request to the prompt version endpoint.
## Example
```python example.py
url = "https://api.respan.ai/api/prompts/{prompt_id}/versions/{version}/"
api_key = "YOUR_RESPAN_API_KEY" # Replace with your actual Respan API key
headers = {
"Authorization": f"Bearer {api_key}",
"Content-Type": "application/json"
}
response = requests.delete(url, headers=headers)
print(response.json())
```
```typescript example.ts
fetch('https://api.respan.ai/api/prompts/{prompt_id}/versions/{version}/',
{
method: 'DELETE',
headers: {
'Content-Type': 'application/json',
'Authorization': 'Bearer YOUR_RESPAN_API_KEY'
}
})
.then(response => response.json())
.then(data => console.log(data));
```
Authentication
AuthorizationBearer
API key authentication. Get your API key from https://platform.respan.ai/platform/api-keys
Path parameters
prompt_id
Prompt Id
version
Version
Response
No content
Errors
401
Unauthorized Error