Skip to main content
POST
/
file
/
getuUloadurl
Get File Upload URL (Legacy)
curl --request POST \
  --url https://server26-dot-royalti-project.uc.r.appspot.com/file/getuUloadurl \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "royaltySource": "testsource",
  "accountingPeriod": "2017-05-01",
  "salePeriod": "2017-01-01",
  "fileMetaData": {
    "uploadType": "royalty",
    "originalname": "export.csv",
    "mimetype": "csv"
  }
}'
{
  "signedUrl": "https://storage.googleapis.com/royalti-uploads/royalty/file-uuid-123?signature=..."
}
This endpoint requires authentication. Include your Bearer token in the Authorization header.

Code Examples

const response = await fetch('https://server26-dot-royalti-project.uc.r.appspot.com/file/getuUloadurl', {
  method: 'POST',
  headers: {
    'Authorization': `Bearer ${token}`,
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
    "royaltySource": "sample-royaltySource",
    "accountingPeriod": "2024-01-21",
    "salePeriod": "2024-01-21",
    "fileMetaData": {}
  })
});

const data = await response.json();
console.log(data);

Authorizations

Authorization
string
header
required

JWT Authorization header using the Bearer scheme. Format: "Bearer {token}"

Body

application/json
royaltySource
string
required
accountingPeriod
string<date>
required
salePeriod
string<date>
required
fileMetaData
object
required

Response

Signed upload URL generated.

signedUrl
string<uri>