Uploading an image
If you wish to upload an image to the Upload API, you can do so by sending a POST request to the https://api.fivemanage.com/api/v3/file endpoint.General
Headers
You need to send anAuthorization header with your API key.
Query parameters
You can also send your API key as a query parameter?apiKey=. This is useful if you are using the Upload API in a browser.
Body
The body of the request should be a form-data object with a file namedfile .
Uploading an image with Axios
Uploading a base64 image
If you have a base64 encoded image, you can upload it using the/v3/file/base64 endpoint. This is particularly useful for environments where FormData is not available or difficult to use, such as some game engines or server-side scripts.
Response
Success
Deleting a file
When we want to delete an image, we can do so by sending a DELETE request to the https://api.fivemanage.com/api/v3/file/:path endpoint. The:path parameter should be the ID or the file path of the image you want to delete. You can get the ID from the response when you upload an image (see above).
Listing images
You can list your uploaded images using a GET request. You can filter by type to only see images.Getting image details
To get details about a specific image, including its metadata, use the GET request with the file ID.Games & Mods
FiveM
You can upload files from Lua using the base64 endpoint.
Screenshot Basic
- Lua
.png?fit=max&auto=format&n=tUtwuHgibAuVylZ9&q=85&s=44653a825fa0664047dae92cd8969b2d)
