Upload Public File

Upload a publicly accessible file such as icons, images, or documents associated with a partner user or card product.

Upload Public File

This endpoint uploads a file to the Netevia platform and makes it publicly accessible. It supports a wide range of file types including user icons, card icons, identity documents, financial statements, and insurance records. The file content is submitted as a base64-encoded string along with metadata identifying the file type, name, and optional associations to a partner user or card product set.

Endpoint

POST /Files/UploadFilePublic

Authentication

Bearer token required. Obtain via:

POST https://api.banking.netevia.dev/api/auth/v2

Include in header: Authorization: Bearer {token}
Token lifetime: 10 minutes. Refresh via POST /api/auth/refresh.

When to use

Use this endpoint to upload images or documents that need to be publicly referenced by the platform, such as card face icons for physical or virtual card products, user profile icons, or compliance documents linked to a partner user. This is appropriate when the uploaded file should be accessible without authentication, for example when card artwork must be rendered by third-party display systems. For sensitive identity or compliance documents that should remain private, consider using the appropriate private file upload endpoint instead.

Request Body

FieldTypeRequiredDescription
datastringNoBase64-encoded binary content of the file to upload
fileTypestringNoMIME type or format descriptor for the file (e.g., image/png)
fileNamestringNoName to assign to the uploaded file, including extension
textstringNoOptional text content or annotation associated with the file
partnerUserIdinteger (int32)NoID of the partner user to associate this file with
templateNotificationinteger (int32)NoIdentifier for a notification template to trigger upon upload
cardProductSetIdstringNoID of the card product set to associate this file with (used for card icons)
typestring (enum)NoCategorizes the file's purpose. See the full list of accepted values below

Accepted values for type:

UserIcon, TransactionIcon, DriverLicense, SocialSecurityNumber, TaxFiling, OperatingAgreement, ArticlesOfIncorporation, BusinessRegistration, BusinessLicense, TaxId_application, Passport, RewardIntegrationImage, Lease_Agreement, Utility_Bill, Other, CardIconSmall, CardIconLarge, UsMilitaryRecordOfService, StateUsMilitaryArmedForcesId, UsTaxForm, W2, Form1099, PhoneBill, CableBill, InternetBill, BankStatement, Statement401k, BrokerageStatement, LifeInsurance, HealthInsurance, AutoInsurance, MunicipalId, StateIssuedId, CertificateOfCitizenship, CourtOrderForLegalNameChange, StateUsPermanentResidentCard, StateConsularIdentificationCard, StateUsBorderCrossingCard, StateUsEmploymentAuthorizationCard, StateTribalId, BirthCertificate, Form5498, Form1098, PayStub, MedicareCard, CardIconLargeBackSide, BurnerCardIconSmall, BurnerCardIconLarge, BurnerCardIconLargeBackSide, SubscriptionIcon, Statement

{
  "data": "iVBORw0KGgoAAAANSUhEUgAAAAUA...",
  "fileType": "image/png",
  "fileName": "card_icon_front.png",
  "text": "Front face icon for Platinum card product",
  "partnerUserId": 10042,
  "templateNotification": null,
  "cardProductSetId": "cps_8a3f92bc1d4e",
  "type": "CardIconLarge"
}

Response

200 OK

The response body is a plain string containing the public URL or file identifier for the uploaded file.

FieldTypeDescription
(body)stringThe publicly accessible URL or unique identifier referencing the uploaded file
"https://cdn.banking.netevia.com/files/public/cps_8a3f92bc1d4e/card_icon_front.png"

Error Codes

CodeWhen it happens
400Missing required fields, invalid base64 encoding, or unsupported file type value
401Token missing, expired, or invalid
403Insufficient permissions to upload files for the specified partner user or card product set
404Referenced partnerUserId or cardProductSetId does not exist
500Internal server error

Common Mistakes

  • Submitting data without base64-encoding the file content — the field expects a base64 string, not raw binary or a file path
  • Using an unsupported string for type — the value must exactly match one of the documented enum entries (case-sensitive)
  • Omitting both cardProductSetId and partnerUserId when the file type requires an association (e.g., CardIconSmall, CardIconLarge) — the file may upload but not be linked to any resource
  • Providing a fileType that does not match the actual content encoded in data, which can cause rendering failures downstream
  • Uploading sensitive identity documents (e.g., DriverLicense, Passport, SocialSecurityNumber) to a public endpoint — use the appropriate private upload endpoint for documents that should not be publicly accessible

Related Endpoints

  • POST /Files/UploadFile — Upload a file with restricted (non-public) access
  • GET /Files/GetFile — Retrieve a previously uploaded file by its identifier
  • POST /Cards/SetCardProduct — Associate card artwork with a card product set after uploading icons

Example

curl -X POST https://api.banking.netevia.dev/Files/UploadFilePublic \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "data": "iVBORw0KGgoAAAANSUhEUgAAAAUA...",
    "fileType": "image/png",
    "fileName": "card_icon_front.png",
    "text": "Front face icon for Platinum card product",
    "partnerUserId": 10042,
    "cardProductSetId": "cps_8a3f92bc1d4e",
    "type": "CardIconLarge"
  }'
Body Params
string | null

base64

string | null
string | null
string | null
int32 | null
int32 | null
string | null
string
enum
Headers
string
enum
Defaults to application/json

Generated from available response content types

Allowed:
string
enum
Defaults to application/json

Generated from available request content types

Allowed:
Response

Language
Credentials
Bearer
JWT
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
text/plain
application/json
text/json