Delete special event
Delete a special event from the collection. Allows museum to cancel planned events.
AuthorizationBasic <token>
In: header
Path Parameters
eventIdstring
Identifier for a special event.
Format
uuid
Cookie Parameters
test?string
Response Body
curl -X DELETE "https://redocly.com/_mock/docs/openapi/museum-api/special-events/dad4bce8-f5cb-4078-a211-995864315e39" \
--cookie "test=string"
fetch("https://redocly.com/_mock/docs/openapi/museum-api/special-events/dad4bce8-f5cb-4078-a211-995864315e39", {
headers: {
"cookie": "test=string"
}
})
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://redocly.com/_mock/docs/openapi/museum-api/special-events/dad4bce8-f5cb-4078-a211-995864315e39"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("Cookie", "test=string")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
import requests
url = "https://redocly.com/_mock/docs/openapi/museum-api/special-events/dad4bce8-f5cb-4078-a211-995864315e39"
response = requests.request("DELETE", url, cookies = {
"test": "string"
})
print(response.text)
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
import java.net.http.HttpResponse.BodyHandlers;
import java.time.Duration;
HttpClient client = HttpClient.newBuilder()
.connectTimeout(Duration.ofSeconds(10))
.build();
HttpRequest.Builder requestBuilder = HttpRequest.newBuilder()
.uri(URI.create("https://redocly.com/_mock/docs/openapi/museum-api/special-events/dad4bce8-f5cb-4078-a211-995864315e39"))
.header("Cookie", "test=string")
.DELETE()
.build();
try {
HttpResponse<String> response = client.send(requestBuilder.build(), BodyHandlers.ofString());
System.out.println("Status code: " + response.statusCode());
System.out.println("Response body: " + response.body());
} catch (Exception e) {
e.printStackTrace();
}
using System;
using System.Net.Http;
using System.Text;
var client = new HttpClient();
client.DefaultRequestHeaders.Add("cookie", "test=string");
var response = await client.DeleteAsync("https://redocly.com/_mock/docs/openapi/museum-api/special-events/dad4bce8-f5cb-4078-a211-995864315e39");
var responseBody = await response.Content.ReadAsStringAsync();
Empty
{
"type": "object",
"title": "Validation failed"
}
{
"type": "object",
"title": "Validation failed"
}
{
"type": "object",
"title": "Validation failed"
}