JSONGenerator
GeneratorSchemaConvertersExamplesDocs

JSONGenerator

Free online tools for generating random JSON data and JSON Schemas.

Quick Links

  • JSON Generator
  • JSON Schema Converter
  • Examples
  • Docs
  • Blog
  • About
  • Contact
  • Privacy Policy

Converters

  • JSON to YAML
  • YAML to JSON
  • XML to JSON
  • JSON to XML
  • JSON to TOML
  • TOML to JSON
  • JSON to CSV
  • CSV to JSON
  • JSON to Excel
  • Excel to JSON
  • JSON to HTML table
  • JSON to TypeScript
  • JSON to C#
  • JSON to Go
  • JSON to Java
  • JSON to SQL

Support

Having issues? Contact us.

© 2026 JSON Generator. All rights reserved.

Dummy order JSON for e-commerce

This template produces 3 to 8 orders. Each order has an ID, one of five statuses (pending, paid, shipped, delivered or refunded), a placement date in 2024 or 2025, a customer with a name and email, one to four line items with a product name, quantity and unit price, and a payment block with a card issuer and card number. The card numbers are random and do not belong to anyone.

Open in JSON Generator

Template

Paste this into the JSON Generator to produce data like the sample below.

{
  "orders": [
    "repeat(3,8)",
    {
      "orderId": "objectId()",
      "status": "enum(pending, paid, shipped, delivered, refunded)",
      "placedAt": "date(2024-01-01, 2025-12-31)",
      "customer": {
        "name": "firstName() lastName()",
        "email": "email()"
      },
      "items": [
        "repeat(1,4)",
        {
          "product": "productName()",
          "quantity": "int(1,5)",
          "unitPrice": "double(5,250,2)"
        }
      ],
      "payment": {
        "issuer": "creditCardIssuer()",
        "card": "creditCardNumber()"
      }
    }
  ]
}

Fields

Fields in the Dummy order JSON for e-commerce template and what each one generates
FieldTemplateWhat it generates
orders[]repeat(3,8)An array of 3–8 items
orders[].orderIdobjectId()
  • objectId(): Generates an ObjectId string which is commonly used with MongoDB.
orders[].statusenum(pending, paid, shipped, delivered, refunded)
  • enum(): Generates a random value from the list of arguments.
orders[].placedAtdate(2024-01-01, 2025-12-31)
  • date(): Generates a random date.
orders[].customer.namefirstName() lastName()
  • firstName(): Generates a random first name.
  • lastName(): Generates a random last name.
orders[].customer.emailemail()
  • email(): Generates a random email address.
orders[].items[]repeat(1,4)An array of 1–4 items
orders[].items[].productproductName()
  • productName(): Generates a random product name.
orders[].items[].quantityint(1,5)
  • int(): Generates a random integer value.
orders[].items[].unitPricedouble(5,250,2)
  • double(): Generates a random double value.
orders[].payment.issuercreditCardIssuer()
  • creditCardIssuer(): Generates a random credit card issuer.
orders[].payment.cardcreditCardNumber()
  • creditCardNumber(): Generates a random credit card number.

Sample output

The first 2 items of each list from one run of the template. Every click on Generate produces new data.

{
  "orders": [
    {
      "orderId": "6b0e1c05a1920ac0471796ef",
      "status": "delivered",
      "placedAt": "2025-03-30T08:54:52.282Z",
      "customer": {
        "name": "Norval Hickle",
        "email": "Clair_Zieme20@yahoo.com"
      },
      "items": [
        {
          "product": "Generic Concrete Soap",
          "quantity": 1,
          "unitPrice": 233.53
        },
        {
          "product": "Licensed Marble Bike",
          "quantity": 5,
          "unitPrice": 7.01
        },
        {
          "product": "Small Steel Bacon",
          "quantity": 2,
          "unitPrice": 177.55
        },
        {
          "product": "Practical Steel Ball",
          "quantity": 5,
          "unitPrice": 20.74
        }
      ],
      "payment": {
        "issuer": "jcb",
        "card": "3036-894464-2847"
      }
    },
    {
      "orderId": "6b0e1c053c741e2b0532aef7",
      "status": "delivered",
      "placedAt": "2024-11-22T21:21:13.348Z",
      "customer": {
        "name": "Sebastian Schaefer",
        "email": "Jaycee73@yahoo.com"
      },
      "items": [
        {
          "product": "Tasty Steel Soap",
          "quantity": 4,
          "unitPrice": 135.62
        }
      ],
      "payment": {
        "issuer": "discover",
        "card": "3637-547045-8047"
      }
    }
  ]
}

Use cases

  • Develop an order history page or admin order list before the backend exists.
  • Test code that totals line items or groups orders by status.
  • Load a staging database with orders that have varying numbers of items.
  • Write API documentation or tutorials with a realistic nested response body.

Related

More sample data: User profiles, Product catalog, Addresses, Flight bookings, Network logs, Employee directory.

See the template tag reference for every tag, browse all examples, or turn your generated data into a contract with the JSON Schema Generator.