Applications
Applications are the foundation for programmatic access to the Local Universe API. Each application gets a bot user and service credentials for authentication.
The application model
Properties
- Name
id- Type
- string
- Description
Unique identifier for the application.
- Name
name- Type
- string
- Description
The name of the application.
- Name
owner- Type
- User
- Description
The user who owns this application.
- Name
bot- Type
- User
- Description
The bot user associated with this application.
- Name
created_at- Type
- string
- Description
When the application was created.
List applications
Returns all applications owned by the authenticated user.
Request
curl https://api.localuniverse.io/v1/applications \
-H "Authorization: Bearer {token}"
Response
[
{
"id": "1344387816333352652",
"name": "My Bot",
"owner": {
"id": "1344387816333399999",
"username": "tino"
},
"bot": {
"id": "1344387816333355555",
"username": "my-bot"
},
"created_at": "2025-02-26T19:17:12.848375Z"
}
]
Create an application
Create a new application. This also creates a bot user and generates service credentials (api_key and api_secret).
Required attributes
- Name
name- Type
- string
- Description
The name of the application.
Request
curl -X POST https://api.localuniverse.io/v1/applications \
-H "Authorization: Bearer {token}" \
-H "Content-Type: application/json" \
-d '{"name": "My Bot"}'
Get an application
Retrieve an application by its ID.
Request
curl https://api.localuniverse.io/v1/applications/1344387816333352652 \
-H "Authorization: Bearer {token}"
Update an application
Optional attributes
- Name
name- Type
- string
- Description
New name for the application.
Request
curl -X PATCH https://api.localuniverse.io/v1/applications/1344387816333352652 \
-H "Authorization: Bearer {token}" \
-H "Content-Type: application/json" \
-d '{"name": "Updated Bot Name"}'
Delete an application
Permanently delete an application and its associated bot user.
Request
curl -X DELETE https://api.localuniverse.io/v1/applications/1344387816333352652 \
-H "Authorization: Bearer {token}"
Update bot user
Update the bot user associated with this application.
Optional attributes
- Name
username- Type
- string
- Description
New username for the bot.
- Name
avatar- Type
- string
- Description
New avatar URL for the bot.
Request
curl -X PATCH https://api.localuniverse.io/v1/applications/1344387816333352652/bot \
-H "Authorization: Bearer {token}" \
-H "Content-Type: application/json" \
-d '{"username": "cool-bot"}'
Reset bot token
Regenerate the service credentials for the bot. The old api_key and api_secret will be invalidated immediately.
The new credentials are only returned in the response. Store them securely — they won't be shown again.
Request
curl -X POST https://api.localuniverse.io/v1/applications/1344387816333352652/bot/reset \
-H "Authorization: Bearer {token}"
