Create a ticket type
curl --request POST \
--url https://openapi.orriven.com/v1/events/{eventId}/ticket-types \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"description": "<string>",
"capacity": 500000,
"allowWaitlist": true,
"isPublic": true,
"requiresApproval": true,
"opensAt": "2023-11-07T05:31:56Z",
"closesAt": "2023-11-07T05:31:56Z",
"priceAmount": 50000000
}
'import requests
url = "https://openapi.orriven.com/v1/events/{eventId}/ticket-types"
payload = {
"name": "<string>",
"description": "<string>",
"capacity": 500000,
"allowWaitlist": True,
"isPublic": True,
"requiresApproval": True,
"opensAt": "2023-11-07T05:31:56Z",
"closesAt": "2023-11-07T05:31:56Z",
"priceAmount": 50000000
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
description: '<string>',
capacity: 500000,
allowWaitlist: true,
isPublic: true,
requiresApproval: true,
opensAt: '2023-11-07T05:31:56Z',
closesAt: '2023-11-07T05:31:56Z',
priceAmount: 50000000
})
};
fetch('https://openapi.orriven.com/v1/events/{eventId}/ticket-types', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://openapi.orriven.com/v1/events/{eventId}/ticket-types",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'description' => '<string>',
'capacity' => 500000,
'allowWaitlist' => true,
'isPublic' => true,
'requiresApproval' => true,
'opensAt' => '2023-11-07T05:31:56Z',
'closesAt' => '2023-11-07T05:31:56Z',
'priceAmount' => 50000000
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://openapi.orriven.com/v1/events/{eventId}/ticket-types"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"capacity\": 500000,\n \"allowWaitlist\": true,\n \"isPublic\": true,\n \"requiresApproval\": true,\n \"opensAt\": \"2023-11-07T05:31:56Z\",\n \"closesAt\": \"2023-11-07T05:31:56Z\",\n \"priceAmount\": 50000000\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://openapi.orriven.com/v1/events/{eventId}/ticket-types")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"capacity\": 500000,\n \"allowWaitlist\": true,\n \"isPublic\": true,\n \"requiresApproval\": true,\n \"opensAt\": \"2023-11-07T05:31:56Z\",\n \"closesAt\": \"2023-11-07T05:31:56Z\",\n \"priceAmount\": 50000000\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://openapi.orriven.com/v1/events/{eventId}/ticket-types")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"capacity\": 500000,\n \"allowWaitlist\": true,\n \"isPublic\": true,\n \"requiresApproval\": true,\n \"opensAt\": \"2023-11-07T05:31:56Z\",\n \"closesAt\": \"2023-11-07T05:31:56Z\",\n \"priceAmount\": 50000000\n}"
response = http.request(request)
puts response.read_body{
"id": "<string>",
"eventId": "<string>",
"name": "<string>",
"description": "<string>",
"capacity": 123,
"allowWaitlist": true,
"isPublic": true,
"requiresApproval": true,
"status": "draft",
"opensAt": "<string>",
"closesAt": "<string>",
"priceAmount": 123,
"sortOrder": 123,
"counts": {
"confirmed": 123,
"waitlisted": 123
},
"createdAt": "<string>"
}{
"error": {
"code": 404,
"status": "NOT_FOUND",
"message": "Event not found.",
"details": [
"<unknown>"
]
}
}{
"error": {
"code": 404,
"status": "NOT_FOUND",
"message": "Event not found.",
"details": [
"<unknown>"
]
}
}{
"error": {
"code": 404,
"status": "NOT_FOUND",
"message": "Event not found.",
"details": [
"<unknown>"
]
}
}{
"error": {
"code": 404,
"status": "NOT_FOUND",
"message": "Event not found.",
"details": [
"<unknown>"
]
}
}Ticket types
Create a ticket type
Born draft — invisible and without effect until opened via PATCH.
POST
/
v1
/
events
/
{eventId}
/
ticket-types
Create a ticket type
curl --request POST \
--url https://openapi.orriven.com/v1/events/{eventId}/ticket-types \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"description": "<string>",
"capacity": 500000,
"allowWaitlist": true,
"isPublic": true,
"requiresApproval": true,
"opensAt": "2023-11-07T05:31:56Z",
"closesAt": "2023-11-07T05:31:56Z",
"priceAmount": 50000000
}
'import requests
url = "https://openapi.orriven.com/v1/events/{eventId}/ticket-types"
payload = {
"name": "<string>",
"description": "<string>",
"capacity": 500000,
"allowWaitlist": True,
"isPublic": True,
"requiresApproval": True,
"opensAt": "2023-11-07T05:31:56Z",
"closesAt": "2023-11-07T05:31:56Z",
"priceAmount": 50000000
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
description: '<string>',
capacity: 500000,
allowWaitlist: true,
isPublic: true,
requiresApproval: true,
opensAt: '2023-11-07T05:31:56Z',
closesAt: '2023-11-07T05:31:56Z',
priceAmount: 50000000
})
};
fetch('https://openapi.orriven.com/v1/events/{eventId}/ticket-types', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://openapi.orriven.com/v1/events/{eventId}/ticket-types",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'description' => '<string>',
'capacity' => 500000,
'allowWaitlist' => true,
'isPublic' => true,
'requiresApproval' => true,
'opensAt' => '2023-11-07T05:31:56Z',
'closesAt' => '2023-11-07T05:31:56Z',
'priceAmount' => 50000000
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://openapi.orriven.com/v1/events/{eventId}/ticket-types"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"capacity\": 500000,\n \"allowWaitlist\": true,\n \"isPublic\": true,\n \"requiresApproval\": true,\n \"opensAt\": \"2023-11-07T05:31:56Z\",\n \"closesAt\": \"2023-11-07T05:31:56Z\",\n \"priceAmount\": 50000000\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://openapi.orriven.com/v1/events/{eventId}/ticket-types")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"capacity\": 500000,\n \"allowWaitlist\": true,\n \"isPublic\": true,\n \"requiresApproval\": true,\n \"opensAt\": \"2023-11-07T05:31:56Z\",\n \"closesAt\": \"2023-11-07T05:31:56Z\",\n \"priceAmount\": 50000000\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://openapi.orriven.com/v1/events/{eventId}/ticket-types")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"capacity\": 500000,\n \"allowWaitlist\": true,\n \"isPublic\": true,\n \"requiresApproval\": true,\n \"opensAt\": \"2023-11-07T05:31:56Z\",\n \"closesAt\": \"2023-11-07T05:31:56Z\",\n \"priceAmount\": 50000000\n}"
response = http.request(request)
puts response.read_body{
"id": "<string>",
"eventId": "<string>",
"name": "<string>",
"description": "<string>",
"capacity": 123,
"allowWaitlist": true,
"isPublic": true,
"requiresApproval": true,
"status": "draft",
"opensAt": "<string>",
"closesAt": "<string>",
"priceAmount": 123,
"sortOrder": 123,
"counts": {
"confirmed": 123,
"waitlisted": 123
},
"createdAt": "<string>"
}{
"error": {
"code": 404,
"status": "NOT_FOUND",
"message": "Event not found.",
"details": [
"<unknown>"
]
}
}{
"error": {
"code": 404,
"status": "NOT_FOUND",
"message": "Event not found.",
"details": [
"<unknown>"
]
}
}{
"error": {
"code": 404,
"status": "NOT_FOUND",
"message": "Event not found.",
"details": [
"<unknown>"
]
}
}{
"error": {
"code": 404,
"status": "NOT_FOUND",
"message": "Event not found.",
"details": [
"<unknown>"
]
}
}Authorizations
The API key's secret (osk_…), shown once when the key is created in the console.
Path Parameters
Body
application/json
Required string length:
1 - 200Maximum string length:
2000Required range:
1 <= x <= 1000000Required range:
0 <= x <= 100000000Response
The created ticket type.
Available options:
draft, open, closed, archived Show child attributes
Show child attributes
⌘I