contentType enum Constrain content type and filename extension. Omit for a mix.
Generate coherent mock file-upload sessions and multipart records with exact byte progress, lifecycle states, checksums and safe example URLs.
Generated test data for fixtures and development
| Parameter | Type | Default & allowed | Description |
|---|---|---|---|
contentType | enum | allowed: image/png | application/pdf | text/csv | application/zip example: application/pdf | Constrain content type and filename extension. Omit for a mix. |
mode | enum | allowed: single | multipart example: multipart | Constrain single or multipart mode. Explicit multipart requires a total of at least 2 KiB. |
status | enum | allowed: initiated | uploading | completed | failed | expired example: uploading | Constrain lifecycle state and its coherent progress/error fields. |
minSizeBytes | int | default: 1024 allowed: 1 – 104857600 example: 1048576 | Inclusive minimum fictional file size in bytes. |
maxSizeBytes | int | default: 52428800 allowed: 1 – 104857600 example: 20971520 | Inclusive maximum size; must be at least minSizeBytes and at least 2 KiB (2048 bytes) for explicit multipart mode. |
asOf | date | example: 2026-07-10T23:59:59.999Z | Latest lifecycle instant. Defaults to the current UTC day's end and is echoed for replay. |
contentType enum Constrain content type and filename extension. Omit for a mix.
mode enum Constrain single or multipart mode. Explicit multipart requires a total of at least 2 KiB.
status enum Constrain lifecycle state and its coherent progress/error fields.
minSizeBytes int Inclusive minimum fictional file size in bytes.
maxSizeBytes int Inclusive maximum size; must be at least minSizeBytes and at least 2 KiB (2048 bytes) for explicit multipart mode.
asOf date Latest lifecycle instant. Defaults to the current UTC day's end and is echoed for replay.
| Parameter | Type | Default & allowed | Description |
|---|---|---|---|
count | int | default: 10 allowed: 1 – 100 example: 3 | How many records to generate (1–100). |
seed | int | example: 42 | Deterministic output: the same seed always returns the same records. Omit for random (the used seed is echoed in meta.seed). |
fields | list | example: uploadId,fileName | Return only these fields (comma-separated). Mutually exclusive with 'exclude'. |
exclude | list | example: error | Return all fields except these (comma-separated). |
format | enum | default: json allowed: json | ndjson | csv example: csv | Response format: json envelope, ndjson (one record per line) or csv. |
pretty | boolean | default: false example: true | Pretty-print the JSON response. |
unwrap | boolean | default: false example: true | Drop the envelope: return the raw array/object without data/meta wrapper. |
count int How many records to generate (1–100).
seed int Deterministic output: the same seed always returns the same records. Omit for random (the used seed is echoed in meta.seed).
fields list Return only these fields (comma-separated). Mutually exclusive with 'exclude'.
exclude list Return all fields except these (comma-separated).
format enum Response format: json envelope, ndjson (one record per line) or csv.
pretty boolean Pretty-print the JSON response.
unwrap boolean Drop the envelope: return the raw array/object without data/meta wrapper.
| Field | Type | Description | Example |
|---|---|---|---|
uploadId | string | Unique fictional upload id containing the stable record index. | upl_0_a81c42f0 |
fileName | string | Generic filename whose extension agrees with contentType. | document-1.pdf |
contentType | string | Selected mock file media type. | application/pdf |
sizeBytes | integer | Total file bytes inside requested bounds. | 10485760 |
mode | string | single or multipart. | multipart |
status | string | initiated, uploading, completed, failed or expired. | uploading |
createdAt | string (ISO 8601) | Fictional session creation instant. | 2026-07-10T08:00:00.000Z |
expiresAt | string (ISO 8601) | Expiry after createdAt; expired fixtures place it at or before resolved asOf. | 2026-07-17T08:00:00.000Z |
completedAt nullable | string (ISO 8601) | Completion instant for completed sessions only. | null |
uploadedBytes | integer | Bytes received, never above sizeBytes. | 5242880 |
progressPercentage | float | uploadedBytes divided by sizeBytes; only completed sessions equal 100. | 50 |
partSizeBytes | integer | Nominal bytes per part; 1 KiB–10 MiB for multipart and equal to sizeBytes for single mode. | 5242880 |
partCount | integer | One for single mode, otherwise 2–10. | 2 |
completedParts | integer | Fully uploaded parts, from zero through partCount. | 1 |
checksum nullable | string | Fictional sha256 value for completed sessions only. | null |
downloadUrl nullable | string | Safe example.com URL for completed sessions only. | null |
error nullable | object | Code/message for failed or expired sessions; otherwise null. | null |
uploadId string Unique fictional upload id containing the stable record index.
example: upl_0_a81c42f0
fileName string Generic filename whose extension agrees with contentType.
example: document-1.pdf
contentType string Selected mock file media type.
example: application/pdf
sizeBytes integer Total file bytes inside requested bounds.
example: 10485760
mode string single or multipart.
example: multipart
status string initiated, uploading, completed, failed or expired.
example: uploading
createdAt string (ISO 8601) Fictional session creation instant.
example: 2026-07-10T08:00:00.000Z
expiresAt string (ISO 8601) Expiry after createdAt; expired fixtures place it at or before resolved asOf.
example: 2026-07-17T08:00:00.000Z
completedAt string (ISO 8601) nullable Completion instant for completed sessions only.
example: null
uploadedBytes integer Bytes received, never above sizeBytes.
example: 5242880
progressPercentage float uploadedBytes divided by sizeBytes; only completed sessions equal 100.
example: 50
partSizeBytes integer Nominal bytes per part; 1 KiB–10 MiB for multipart and equal to sizeBytes for single mode.
example: 5242880
partCount integer One for single mode, otherwise 2–10.
example: 2
completedParts integer Fully uploaded parts, from zero through partCount.
example: 1
checksum string nullable Fictional sha256 value for completed sessions only.
example: null
downloadUrl string nullable Safe example.com URL for completed sessions only.
example: null
error object nullable Code/message for failed or expired sessions; otherwise null.
example: null
/api/file-uploads?contentType=application%2Fpdf&mode=multipart&status=uploading&minSizeBytes=1048576&maxSizeBytes=20971520&seed=42&count=20 {
"data": [
{
"uploadId": "upl_0_8016cfb6",
"fileName": "document-1.pdf",
"contentType": "application/pdf",
"sizeBytes": 10567395,
"mode": "multipart",
"status": "uploading",
"createdAt": "2026-07-29T16:20:30.607Z",
"expiresAt": "2026-08-05T16:20:30.607Z",
"completedAt": null,
"uploadedBytes": 6320402,
"progressPercentage": 59.81,
"partSizeBytes": 1320925,
"partCount": 8,
"completedParts": 4,
"checksum": null,
"downloadUrl": null,
"error": null
},
{
"uploadId": "upl_1_f248abec",
"fileName": "document-2.pdf",
"contentType": "application/pdf",
"sizeBytes": 1836467,
"mode": "multipart",
"status": "uploading",
"createdAt": "2026-07-29T11:20:54.348Z",
"expiresAt": "2026-08-05T11:20:54.348Z",
"completedAt": null,
"uploadedBytes": 820989,
"progressPercentage": 44.7,
"partSizeBytes": 918234,
"partCount": 2,
"completedParts": 0,
"checksum": null,
"downloadUrl": null,
"error": null
},
…
"generatedAt": "2026-07-29T08:13:22.000Z"
}
} /api/file-uploads?contentType=image%2Fpng&status=completed&count=10 {
"data": [
{
"uploadId": "upl_0_016cfb6a",
"fileName": "image-1.png",
"contentType": "image/png",
"sizeBytes": 25050058,
"mode": "multipart",
"status": "completed",
"createdAt": "2026-07-29T16:20:30.607Z",
"expiresAt": "2026-08-05T16:20:30.607Z",
"completedAt": "2026-07-29T20:23:39.784Z",
"uploadedBytes": 25050058,
"progressPercentage": 100,
"partSizeBytes": 3578580,
"partCount": 7,
"completedParts": 7,
"checksum": "sha256:5c85eac58cdd40fb15863c1d1cff8728448a0b56b87c24316010d14615edf362",
"downloadUrl": "https://files.example.com/download/upl_0_016cfb6a/image-1.png",
"error": null
},
{
"uploadId": "upl_1_8f248abe",
"fileName": "image-2.png",
"contentType": "image/png",
"sizeBytes": 2074382,
"mode": "single",
"status": "completed",
"createdAt": "2026-07-29T23:51:39.295Z",
"expiresAt": "2026-08-05T23:51:39.295Z",
"completedAt": "2026-07-29T23:55:23.134Z",
"uploadedBytes": 2074382,
"progressPercentage": 100,
"partSizeBytes": 2074382,
"partCount": 1,
"completedParts": 1,
"checksum": "sha256:ccba6fd45df91c36673e8fcae90de6555855da26d0b749e25c7ba8ef202f9e4c",
"downloadUrl": "https://files.example.com/download/upl_1_8f248abe/image-2.png",
"error": null
},
…
"generatedAt": "2026-07-29T08:13:22.000Z"
}
} | Parameter | Type | Default & allowed | Description |
|---|---|---|---|
uploadId | string | default: upl_demo allowed: 1 – 64 example: upl_checkout_assets | Safe upload id echoed in every part. |
partSizeBytes | int | default: 5242880 allowed: 1024 – 10485760 example: 1048576 | Exact size and offset step for each generated part. |
status | enum | allowed: pending | uploading | completed | failed example: completed | Constrain part lifecycle status and coherent fields. |
asOf | date | example: 2026-07-10T23:59:59.999Z | Latest part update instant. Defaults to the current UTC day's end and is echoed for replay. |
uploadId string Safe upload id echoed in every part.
partSizeBytes int Exact size and offset step for each generated part.
status enum Constrain part lifecycle status and coherent fields.
asOf date Latest part update instant. Defaults to the current UTC day's end and is echoed for replay.
| Parameter | Type | Default & allowed | Description |
|---|---|---|---|
count | int | default: 10 allowed: 1 – 100 example: 3 | How many records to generate (1–100). |
seed | int | example: 42 | Deterministic output: the same seed always returns the same records. Omit for random (the used seed is echoed in meta.seed). |
fields | list | example: partId,uploadId | Return only these fields (comma-separated). Mutually exclusive with 'exclude'. |
exclude | list | example: updatedAt | Return all fields except these (comma-separated). |
format | enum | default: json allowed: json | ndjson | csv example: csv | Response format: json envelope, ndjson (one record per line) or csv. |
pretty | boolean | default: false example: true | Pretty-print the JSON response. |
unwrap | boolean | default: false example: true | Drop the envelope: return the raw array/object without data/meta wrapper. |
count int How many records to generate (1–100).
seed int Deterministic output: the same seed always returns the same records. Omit for random (the used seed is echoed in meta.seed).
fields list Return only these fields (comma-separated). Mutually exclusive with 'exclude'.
exclude list Return all fields except these (comma-separated).
format enum Response format: json envelope, ndjson (one record per line) or csv.
pretty boolean Pretty-print the JSON response.
unwrap boolean Drop the envelope: return the raw array/object without data/meta wrapper.
| Field | Type | Description | Example |
|---|---|---|---|
partId | string | Unique fixture part id containing the stable part number. | part_1_a81c42f0 |
uploadId | string | Validated requested upload id. | upl_demo |
partNumber | integer | One-based sequential part number. | 1 |
offsetBytes | integer | Zero-based byte offset: (partNumber - 1) × sizeBytes. | 0 |
sizeBytes | integer | Requested fixed part size. | 5242880 |
status | string | pending, uploading, completed or failed. | completed |
uploadedBytes | integer | Bytes received for this part, never above sizeBytes. | 5242880 |
progressPercentage | float | Exact byte progress; completed alone reports 100. | 100 |
etag nullable | string | Fictional quoted ETag for completed parts only. | "31f0a82d9c41" |
checksum nullable | string | Fictional sha256 value for completed parts only. | sha256:66f327f276cc47a8b2caa2cf7131537a |
error nullable | object | Failure code/message for failed parts only. | null |
updatedAt | string (ISO 8601) | Stable fictional instant at or before resolved asOf. | 2026-07-10T00:00:01.412Z |
partId string Unique fixture part id containing the stable part number.
example: part_1_a81c42f0
uploadId string Validated requested upload id.
example: upl_demo
partNumber integer One-based sequential part number.
example: 1
offsetBytes integer Zero-based byte offset: (partNumber - 1) × sizeBytes.
example: 0
sizeBytes integer Requested fixed part size.
example: 5242880
status string pending, uploading, completed or failed.
example: completed
uploadedBytes integer Bytes received for this part, never above sizeBytes.
example: 5242880
progressPercentage float Exact byte progress; completed alone reports 100.
example: 100
etag string nullable Fictional quoted ETag for completed parts only.
example: "31f0a82d9c41"
checksum string nullable Fictional sha256 value for completed parts only.
example: sha256:66f327f276cc47a8b2caa2cf7131537a
error object nullable Failure code/message for failed parts only.
example: null
updatedAt string (ISO 8601) Stable fictional instant at or before resolved asOf.
example: 2026-07-10T00:00:01.412Z
/api/file-uploads/parts?uploadId=upl_checkout_assets&partSizeBytes=1048576&status=completed&seed=42&count=20 {
"data": [
{
"partId": "part_1_7a958016",
"uploadId": "upl_checkout_assets",
"partNumber": 1,
"offsetBytes": 0,
"sizeBytes": 1048576,
"status": "completed",
"uploadedBytes": 1048576,
"progressPercentage": 100,
"etag": "\"cfb6a5c85eac58cdd40fb158\"",
"checksum": "sha256:63c1d1cff8728448a0b56b87c24316010d14615edf3629ff11dec8095cf56531",
"error": null,
"updatedAt": "2026-07-29T23:59:59.839Z"
},
{
"partId": "part_2_0078f248",
"uploadId": "upl_checkout_assets",
"partNumber": 2,
"offsetBytes": 1048576,
"sizeBytes": 1048576,
"status": "completed",
"uploadedBytes": 1048576,
"progressPercentage": 100,
"etag": "\"abeccba6fd45df91c36673e8\"",
"checksum": "sha256:fcae90de6555855da26d0b749e25c7ba8ef202f9e4c30de268a9b03c9f6b8615",
"error": null,
"updatedAt": "2026-07-29T23:59:58.691Z"
},
{
"partId": "part_3_d1579090",
"uploadId": "upl_checkout_assets",
"partNumber": 3,
"offsetBytes": 2097152,
"sizeBytes": 1048576,
"status": "completed",
"uploadedBytes": 1048576,
"progressPercentage": 100,
"etag": "\"2c05ac838fecf0b9c4166f96\"",
…
"generatedAt": "2026-07-29T08:13:22.000Z"
}
} /api/file-uploads/parts?uploadId=upl_demo&count=10 {
"data": [
{
"partId": "part_1_958016cf",
"uploadId": "upl_demo",
"partNumber": 1,
"offsetBytes": 0,
"sizeBytes": 5242880,
"status": "uploading",
"uploadedBytes": 3550782,
"progressPercentage": 67.73,
"etag": null,
"checksum": null,
"error": null,
"updatedAt": "2026-07-29T23:59:59.298Z"
},
{
"partId": "part_2_078f248a",
"uploadId": "upl_demo",
"partNumber": 2,
"offsetBytes": 5242880,
"sizeBytes": 5242880,
"status": "pending",
"uploadedBytes": 0,
"progressPercentage": 0,
"etag": null,
"checksum": null,
"error": null,
"updatedAt": "2026-07-29T23:59:58.266Z"
},
{
"partId": "part_3_5790902c",
"uploadId": "upl_demo",
"partNumber": 3,
"offsetBytes": 10485760,
"sizeBytes": 5242880,
"status": "failed",
"uploadedBytes": 623925,
"progressPercentage": 11.9,
"etag": null,
…
"generatedAt": "2026-07-29T08:13:22.000Z"
}
} Generates fictional file upload fixtures for progress components, multipart tables and storage workflow tests. Session state is internally coherent: initiated uploads have zero bytes, completed uploads have every byte and part, and failed or expired sessions carry an error while never exposing a download URL. Checksums and download URLs exist only after completion.
Single uploads always have one part. Multipart sessions have 2–10 parts whose nominal size stays between 1 KiB and 10 MiB, matching the accepted /parts range; an explicitly multipart total below 2 KiB is rejected. completedParts never exceeds partCount, and uploadedBytes never exceeds sizeBytes. Progress is calculated from those exact byte counts rather than sampled independently. The resolved asOf clock defaults to the current UTC day's end and is echoed so seeded timestamps can be replayed.
/parts emits sequential part records for one validated upload id. partNumber is recordIndex + 1, offsets are exact multiples of partSizeBytes, and completed parts alone receive an ETag and checksum. Filenames are generic, URLs use example.com, and no signed query strings, tokens, local paths, user names or original customer filenames are generated.
Yes. progressPercentage is calculated directly from uploadedBytes and sizeBytes; only completed records report 100.
Session checksum and downloadUrl are present only for completed uploads. Other states return both fields as null.
Yes. The parts route uses partNumber minus one multiplied by partSizeBytes, so records form a contiguous fixed-size sequence.
No. URLs use the safe example.com domain and never include signatures, credentials or query tokens.
Fake file metadata — kebab-case names, the correct MIME type for every extension, plausible per-kind sizes, unix paths and seeded SHA-256-style checksums.
The complete IANA media type registry with file extensions merged in — look up any type or extension, or strictly parse a Content-Type value into its parts.
Generate coherent mock CloudEvents 1.0 structured JSON envelopes with all required context attributes and action-specific event data.
The complete IANA HTTP status code registry with practical descriptions, defining RFCs and a retryable flag — list by category or look up a single code.