Downloadable Files
Get Downloadable Files
GEThttps://api.paynow.gg/v1/stores/{storeId}/products/{productId}/downloadable-files
Headers
AuthorizationAPI KeyRequired
Authentication token for this request, sent as
Authorization: APIKey TOKEN.Path parameters
storeIdFlakeIdRequired
productIdFlakeIdRequired
Response
200OKProductDownloadableFileDto[]
Show fieldsHide fields
created_atstringRequired
created_byActorDtoRequired
typeenumRequired
Possible enum values
anonymoususerapi_keycustomergame_serverinternaladminplatformglobal_customer
idFlakeIdOptional
idFlakeIdRequired
is_uploadedbooleanRequired
product_idFlakeIdRequired
store_idFlakeIdRequired
descriptionstringOptional
file_content_typestringOptional
file_hashstringOptional
file_namestringOptional
file_sizeintegerOptional
updated_atstringOptional
updated_byActorDtoOptional
typeenumRequired
Possible enum values
anonymoususerapi_keycustomergame_serverinternaladminplatformglobal_customer
idFlakeIdOptional
Failed requests return a PayNowError body. See the error response guide.
curl -X GET "https://api.paynow.gg/v1/stores/{storeId}/products/{productId}/downloadable-files" \
-H "Authorization: APIKey TOKEN"import { createManagementClient } from "@paynow-gg/typescript-sdk";
const paynow = createManagementClient({
apiKey: "API_KEY",
storeId: "STORE_ID",
});
const result = await paynow.downloadableFiles.getDownloadableFiles("411486491630370816");import requests
headers = {"Authorization": "APIKey TOKEN"}
response = requests.get("https://api.paynow.gg/v1/stores/{storeId}/products/{productId}/downloadable-files", headers=headers)Response200
[
{
"created_at": "2024-01-01T00:00:00Z",
"created_by": {
"type": "anonymous",
"id": "411486491630370816"
},
"id": "411486491630370816",
"is_uploaded": true,
"product_id": "411486491630370816",
"store_id": "411486491630370816",
"file_name": "string",
"file_content_type": "string",
"file_size": 0,
"file_hash": "string",
"description": "string",
"updated_at": "2024-01-01T00:00:00Z",
"updated_by": {
"type": "anonymous",
"id": "411486491630370816"
}
}
]Start Downloadable File Upload
POSThttps://api.paynow.gg/v1/stores/{storeId}/products/{productId}/downloadable-files
Headers
AuthorizationAPI KeyRequired
Authentication token for this request, sent as
Authorization: APIKey TOKEN.Path parameters
storeIdFlakeIdRequired
productIdFlakeIdRequired
Request body
file_content_typestringRequired
file_namestringRequired
descriptionstringOptional
curl -X POST "https://api.paynow.gg/v1/stores/{storeId}/products/{productId}/downloadable-files" \
-H "Authorization: APIKey TOKEN" \
-H "Content-Type: application/json" \
-d '{
"file_content_type": "string",
"file_name": "string",
"description": "string"
}'import { createManagementClient } from "@paynow-gg/typescript-sdk";
const paynow = createManagementClient({
apiKey: "API_KEY",
storeId: "STORE_ID",
});
await paynow.downloadableFiles.startDownloadableFileUpload("411486491630370816", {
file_content_type: "string",
file_name: "string",
description: "string",
});import requests
headers = {"Authorization": "APIKey TOKEN"}
payload = {
"file_content_type": "string",
"file_name": "string",
"description": "string",
}
response = requests.post("https://api.paynow.gg/v1/stores/{storeId}/products/{productId}/downloadable-files", headers=headers, json=payload)Finish Downloadable File Upload
POSThttps://api.paynow.gg/v1/stores/{storeId}/products/{productId}/downloadable-files/{downloadableFileId}/finish
Headers
AuthorizationAPI KeyRequired
Authentication token for this request, sent as
Authorization: APIKey TOKEN.Path parameters
storeIdFlakeIdRequired
productIdFlakeIdRequired
downloadableFileIdFlakeIdRequired
curl -X POST "https://api.paynow.gg/v1/stores/{storeId}/products/{productId}/downloadable-files/{downloadableFileId}/finish" \
-H "Authorization: APIKey TOKEN"import { createManagementClient } from "@paynow-gg/typescript-sdk";
const paynow = createManagementClient({
apiKey: "API_KEY",
storeId: "STORE_ID",
});
await paynow.downloadableFiles.finishDownloadableFileUpload("411486491630370816", "411486491630370816");import requests
headers = {"Authorization": "APIKey TOKEN"}
response = requests.post("https://api.paynow.gg/v1/stores/{storeId}/products/{productId}/downloadable-files/{downloadableFileId}/finish", headers=headers)Create Download Url
GEThttps://api.paynow.gg/v1/stores/{storeId}/products/{productId}/downloadable-files/{downloadableFileId}/download-url
Headers
AuthorizationAPI KeyRequired
Authentication token for this request, sent as
Authorization: APIKey TOKEN.Path parameters
storeIdFlakeIdRequired
productIdFlakeIdRequired
downloadableFileIdFlakeIdRequired
Response
200OKCreateDownloadableFileDownloadUrlResponseDto
Show fieldsHide fields
download_signed_urlstringRequired
Failed requests return a PayNowError body. See the error response guide.
curl -X GET "https://api.paynow.gg/v1/stores/{storeId}/products/{productId}/downloadable-files/{downloadableFileId}/download-url" \
-H "Authorization: APIKey TOKEN"import { createManagementClient } from "@paynow-gg/typescript-sdk";
const paynow = createManagementClient({
apiKey: "API_KEY",
storeId: "STORE_ID",
});
const result = await paynow.downloadableFiles.createDownloadUrl("411486491630370816", "411486491630370816");import requests
headers = {"Authorization": "APIKey TOKEN"}
response = requests.get("https://api.paynow.gg/v1/stores/{storeId}/products/{productId}/downloadable-files/{downloadableFileId}/download-url", headers=headers)Response200
{
"download_signed_url": "string"
}Delete Downloadable File
DELETEhttps://api.paynow.gg/v1/stores/{storeId}/products/{productId}/downloadable-files/{downloadableFileId}
Headers
AuthorizationAPI KeyRequired
Authentication token for this request, sent as
Authorization: APIKey TOKEN.Path parameters
storeIdFlakeIdRequired
productIdFlakeIdRequired
downloadableFileIdFlakeIdRequired
curl -X DELETE "https://api.paynow.gg/v1/stores/{storeId}/products/{productId}/downloadable-files/{downloadableFileId}" \
-H "Authorization: APIKey TOKEN"import { createManagementClient } from "@paynow-gg/typescript-sdk";
const paynow = createManagementClient({
apiKey: "API_KEY",
storeId: "STORE_ID",
});
await paynow.downloadableFiles.deleteDownloadableFile("411486491630370816", "411486491630370816");import requests
headers = {"Authorization": "APIKey TOKEN"}
response = requests.delete("https://api.paynow.gg/v1/stores/{storeId}/products/{productId}/downloadable-files/{downloadableFileId}", headers=headers)