Base64 Decoder
platform.base64_decode
Overview
You pass a Base64 string (inline or via file reference); we decode it per RFC 4648 with alphabet validation and a bounded decoded-byte ceiling. Return decoded text (UTF-8 or your chosen encoding) or re-encoded standard Base64 for binary-safe transport. Do not use this to encode data or decrypt ciphertext. Accepts file input via file_ref — no need to extract file content first.
You meet Base64 everywhere — API responses, embedded certificates, config values — and decoding it by hand invites alphabet and padding mistakes. We decode it with a size ceiling so a huge payload cannot exhaust memory.
Reliability
STRICT and deterministic — the same Base64 text with the same options always gives you the same bytes. Decoding is not decryption and not authentication: anything encoded this way was never protected, so treat the result as untrusted input. Input validation (not retryable): no encoded input, or both an inline value and a file reference; text that is not valid for the alphabet you declared, including bad padding; a textEncoding this platform does not know; maxDecodedBytes outside 1 to 5242880; a payload that decodes to more than maxDecodedBytes.
Context footprint
Pure computation with no I/O. Enforces max decoded size to prevent memory abuse. Returns instantly. A successful call costs 1 execution credit.
When to use it
When you have a Base64 string and want the bytes back, either as text or re-encoded for binary-safe transport.
When you want to go the other way (use platform.base64_encode), when the payload is encrypted rather than encoded, or when it decodes to more than 5 MB.
Scope
Non-goals
- Does not encode data (use platform.base64_encode)
- Does not decrypt or verify signatures
- Does not handle streaming or chunked decoding
Properties
Capabilities
Cost & billing
Flat rate per invocation
File handling
File limits
Constraints this skill applies to your input and generated files. The “Limited by” column shows the static source of each cap; none of these can be raised by upgrading your plan.
| Limit | Value | Limited by |
|---|---|---|
| Maximum size per input file | 6.7 MiB | Skill and platform maximum |
How we handle your data
What this means
This skill may receive sensitive content and may return submitted, transformed, extracted, or reformatted content.
Squillify guarantees
- Runs inside Squillify
- This skill runs inside Squillify.
- Payloads are not sent to an external service by this skill.
- Squillify does not permanently store submitted payloads.
- Telemetry records metadata only, not submitted content.
- Submitted payloads are not used for training.
- Submitted payloads are not reviewed by humans.
- This skill does not target sensitive data.
- The response may contain submitted or transformed content.
Your responsibility
Squillify does not determine whether submitted content is sensitive. Your application is responsible for deciding what data it is allowed to submit. Your application is responsible for securing the response.
Input schema
| Field | Type | Required | Description |
|---|---|---|---|
| encoded | string | No | Bounded inline Base64 text; omit it when encoded_file_ref is the source. |
| encoded_file_ref | string | No | Tenant-scoped file reference containing Base64 text; omit it when encoded is the source. |
| urlSafe | boolean | No | Whether input uses Base64url; omit it for false. |
| outputFormat | string | No | Output representation; omit it for text. |
| textEncoding | string | No | Decoded-text charset; omit it for UTF-8. |
| maxDecodedBytes | integer | No | Caller ceiling for decoded bytes; omit it for 5 MiB. |
Output schema
| Field | Type | Required | Description |
|---|---|---|---|
| decodedBytes | integer | Yes | Decoded byte count after alphabet and padding checks. |
| alphabet | string | Yes | Applied alphabet, either base64 or base64url. |
| outputFormat | string | Yes | Applied output representation. |
| text | string | No | Bounded decoded payload representation. |
| dataBase64 | string | No | Bounded decoded payload representation. |
| textEncoding | string | No | Canonical decoded-text charset. |
API contract
POST /v1/executecurl -sS -X POST "$BASE/v1/execute" -H "Authorization: Bearer $KEY" -H 'Content-Type: application/json' -d '{"skillKey":"platform.base64_decode","input":{"encoded":"SGVsbG8sIFdvcmxkIQ==","outputFormat":"text"}}'import { Squillify } from "@squillify/sdk";
const sq = new Squillify({ apiKey: process.env.SQUILLIFY_API_KEY });
const { output } = await sq.execute("platform.base64_decode", {"encoded":"SGVsbG8sIFdvcmxkIQ==","outputFormat":"text"});Errors
| Code | HTTP | Retryable | Description |
|---|---|---|---|
| VALIDATION_ERROR | 400 | No | The request payload failed schema validation. |
| UNAUTHORIZED | 401 | No | Missing or invalid API key. |
| SKILL_NOT_ACCESSIBLE | 403 | No | The API key is not granted access to this skill. |
| SKILL_NOT_AVAILABLE_FOR_PLAN | 403 | No | This skill is not included in your current plan. |
| PLAN_ELIGIBILITY_UNAVAILABLE | 503 | Yes | Plan eligibility could not be decided. Retry after backoff. |
| SKILL_NOT_FOUND | 404 | No | The requested skill or version does not exist. |
| TENANT_RATE_LIMITED | 429 | Yes | Request rate limit exceeded. Retry after backoff. |
| QUOTA_EXCEEDED | 429 | Yes | Plan quota exhausted. Retryable once the quota period resets. |
| EXECUTION_TIMEOUT | 504 | Yes | Execution exceeded the allowed time budget. |
Other limits
| Limit | Value |
|---|---|
| Recommended inline bytes | 32 KiB |
Limitations
- Does not encode data (use platform.base64_encode)
- Does not decrypt or verify signatures
- Does not handle streaming or chunked decoding
- Encoding data to Base64
- Processing encrypted data
- Decoding very large blobs beyond the size limit
How to call
POST /v1/execute (requires authentication)
{
"skillKey": "platform.base64_decode",
"input": {
"encoded": "SGVsbG8sIFdvcmxkIQ==",
"outputFormat": "text"
}
}Examples
Decode Base64 to text
{
"encoded": "SGVsbG8sIFdvcmxkIQ==",
"outputFormat": "text"
}{
"alphabet": "base64",
"decodedBytes": 13,
"textEncoding": "UTF-8",
"text": "Hello, World!",
"outputFormat": "text"
}Decode to binary-safe Base64 output
{
"encoded": "aGVsbG8=",
"outputFormat": "base64"
}{
"decodedBytes": 5,
"outputFormat": "base64",
"dataBase64": "aGVsbG8=",
"alphabet": "base64"
}Recommended use cases
- Decode Base64 payloads received from APIs
- Extract text from Base64-encoded content
- Validate Base64 integrity before processing
- Convert Base64-encoded configuration values to plaintext
Avoid for
- Encoding data to Base64
- Processing encrypted data
- Decoding very large blobs beyond the size limit
Related skills
Composable with
Safety & privacy
- Runs without calling any external service.
- Your payloads are never stored permanently.
- Telemetry captures metadata only — never your payload contents.
- We never train models on your payloads.
- No human reviews your payloads.