Download OpenAPI specification:Download
API specification for GovEntry services
All API endpoints require authentication using a JWT Bearer token. Include the token in the Authorization header:
Authorization: Bearer <your_token_here>
Create new venues or update existing ones.
id | string^[a-zA-Z0-9_@-]+$ Unique identifier for the venue. |
string or null Opening time of the venue. Must be before closes_at. | |
string or null Closing time of the venue. | |
Array of objects (Metadata) Additional metadata for the venue. Must be after opens_at. |
[- {
- "id": "function-room-1",
- "opens_at": "2023-10-01T09:00:00+08:00",
- "closes_at": "2023-10-01T17:00:00+08:00",
- "metadata": [
- {
- "key": "Postal Code",
- "value": "199137"
}, - {
- "key": "Address",
- "value": "5 Jln Pinang"
}
]
}, - {
- "id": "function-room-2",
- "opens_at": "2023-10-02T10:00:00+08:00",
- "closes_at": "2023-10-02T18:00:00+08:00",
- "metadata": [
- {
- "key": "Postal Code",
- "value": "397628"
}, - {
- "key": "Address",
- "value": "1 Stadium Pl"
}
]
}
]
[- {
- "id": "function-room-1",
- "opens_at": "2023-10-01T09:00:00+08:00",
- "closes_at": "2023-10-01T17:00:00+08:00",
- "created_at": "2023-10-01T09:00:00+08:00",
- "updated_at": "2023-10-01T09:00:00+08:00",
- "metadata": [
- {
- "key": "Postal Code",
- "value": "199137"
}, - {
- "key": "Address",
- "value": "5 Jln Pinang"
}
]
}, - {
- "id": "function-room-2",
- "opens_at": "2023-10-02T10:00:00+08:00",
- "closes_at": "2023-10-02T18:00:00+08:00",
- "created_at": "2023-10-01T09:00:00+08:00",
- "updated_at": "2023-10-01T09:00:00+08:00",
- "metadata": [
- {
- "key": "Postal Code",
- "value": "397628"
}, - {
- "key": "Address",
- "value": "1 Stadium Pl"
}
]
}
]
Retrieve details of venues.
id | string Example: id=function-room-1 The ID of the venue to retrieve. If an |
[- {
- "id": "function-room-1",
- "opens_at": "2023-10-01T09:00:00+08:00",
- "closes_at": "2023-10-01T17:00:00+08:00",
- "metadata": [
- {
- "key": "Postal Code",
- "value": "199137"
}, - {
- "key": "Address",
- "value": "5 Jln Pinang"
}
], - "created_at": "2023-10-01T08:00:00+08:00",
- "updated_at": "2023-10-01T10:00:00+08:00"
}, - {
- "id": "function-room-2",
- "opens_at": "2023-10-02T10:00:00+08:00",
- "closes_at": "2023-10-02T18:00:00+08:00",
- "metadata": [
- {
- "key": "Postal Code",
- "value": "397628"
}, - {
- "key": "Address",
- "value": "1 Stadium Pl"
}
], - "created_at": "2023-10-02T08:00:00+08:00",
- "updated_at": "2023-10-02T10:00:00+08:00"
}
]
Update details of an existing venue.
id required | string Example: id=function-room-1 The ID of the venue to update. |
string or null Updated opening time of the venue. Must be before closes_at. | |
string or null Updated closing time of the venue. Must be after opens_at. | |
Array of objects (Metadata) Updated metadata for the venue. |
{- "opens_at": "2023-10-01T09:00:00+08:00",
- "closes_at": "2023-10-01T17:00:00+08:00",
- "metadata": {
- "key": "Accessibility Needs",
- "value": "Wheelchair"
}
}
{- "id": "function-room-1",
- "opens_at": "2023-10-01T09:00:00+08:00",
- "closes_at": "2023-10-01T17:00:00+08:00",
- "metadata": {
- "key": "Accessibility Needs",
- "value": "Wheelchair"
}, - "created_at": "2023-10-01T08:00:00+08:00",
- "updated_at": "2023-10-01T10:00:00+08:00"
}
Create new attendees or update existing ones.
id | string Unique identifier for the attendee. |
place_ids | Array of strings List of place IDs the attendee is associated with. |
Array of objects (Metadata) Additional metadata for the attendee. |
[- {
- "id": "ATTENDEE-123",
- "place_ids": [
- "function-room-1",
- "function-room-2"
], - "metadata": [
- {
- "key": "Accessibility Needs",
- "value": "Wheelchair"
}, - {
- "key": "Dietary Preference",
- "value": "Vegetarian"
}
]
}, - {
- "id": "ATTENDEE-456",
- "place_ids": [
- "function-room-3"
], - "metadata": [
- {
- "key": "Accessibility Needs",
- "value": "Handicapped Parking"
}, - {
- "key": "Dietary Preference",
- "value": "Halal"
}
]
}
]
[- {
- "id": "ATTENDEE-123",
- "place_ids": [
- "function-room-1",
- "function-room-2"
], - "metadata": {
- "key": "Accessibility Needs",
- "value": "Wheelchair"
}, - "created_at": "2023-10-01T08:00:00+08:00",
- "updated_at": "2023-10-01T10:00:00+08:00"
}
]
Retrieve details of attendees.
id | string Example: id=ATTENDEE-123 The ID of the attendee to retrieve. If an |
[- {
- "id": "ATTENDEE-123",
- "place_ids": [
- "function-room-1",
- "function-room-2"
], - "metadata": [
- {
- "key": "Dietary Preference",
- "value": "Vegetarian"
}
], - "created_at": "2023-10-01T08:00:00+08:00",
- "updated_at": "2023-10-01T10:00:00+08:00"
}, - {
- "id": "ATTENDEE-456",
- "place_ids": [
- "function-room-3"
], - "metadata": [
- {
- "key": "Accessibility Needs",
- "value": "Wheelchair"
}
], - "created_at": "2023-10-02T08:00:00+08:00",
- "updated_at": "2023-10-02T10:00:00+08:00"
}
]
Update details of an existing attendee.
id required | string Example: id=ATTENDEE-123 The ID of the attendee to update. |
place_ids | Array of strings Updated list of place IDs the attendee is associated with. |
Array of objects (Metadata) Updated metadata for the attendee. |
{- "place_ids": [
- "function-room-3",
- "function-room-4"
], - "metadata": [
- {
- "key": "Accessibility Needs",
- "value": "Wheelchair"
}, - {
- "key": "Dietary Preference",
- "value": "Vegetarian"
}
]
}
{- "id": "ATTENDEE-123",
- "place_ids": [
- "function-room-1",
- "function-room-2"
], - "metadata": {
- "key": "Accessibility Needs",
- "value": "Wheelchair"
}, - "created_at": "2023-10-01T08:00:00+08:00",
- "updated_at": "2023-10-01T10:00:00+08:00"
}
Generates a presigned URL that allows temporary access to upload a file to S3. The URL has a limited validity period.
GET https://{campaign_id}.app.entry.gov.sg/api/v1/files/presign-url?filename=profile.jpg
Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...
With the response from step 1, you can upload a file using the HTTP method specified in the response:
// Example using JavaScript fetch API
async function uploadFile(file) {
// Step 1: Get the presigned URL
const response = await fetch('https://campaign.app.entry.gov.sg/api/v1/files/presign-url?filename=' + file.name, {
method: 'GET',
headers: {
'Authorization': 'Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...'
}
});
const data = await response.json();
// Step 2: Use the presigned URL to upload the file
await fetch(data.presigned_url, {
method: data.method,
body: file,
headers: {
'Content-Type': file.type
}
});
// Return the storage key for future reference
return data.storage_key;
}
# Example using curl
# Step 1: Get the presigned URL
curl -X GET https://campaign.app.entry.gov.sg/api/v1/files/presign-url?filename=profile.jpg \
-H "Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..."
# Step 2: Upload the file using the presigned URL
curl -X PUT PRESIGNED_URL_FROM_PREVIOUS_RESPONSE \
-H "Content-Type: image/jpeg" \
--data-binary /path/to/profile.jpg
For more information on using presigned URLs, see AWS Documentation: Uploading objects using presigned URLs
filename required | string Example: filename=profile.jpg Name of the file to be uploaded |
{- "expires_in": 900,
- "method": "PUT",
- "storage_key": "files/campaign/123e4567-e89b-12d3-a456-426614174000.jpg"
}
Ask Spoon