> ## Documentation Index
> Fetch the complete documentation index at: https://dom-6a1f70d6.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Creer Commande



## OpenAPI

````yaml openapi.json post /clients/commande
openapi: 3.0.3
info:
  title: DELIVERY API
  description: API pour la plateforme fournissant une api de gestion de livraison
  version: 1.0.0
servers: []
security: []
paths:
  /clients/commande:
    post:
      tags:
        - Clients
        - Clients
      summary: Creer Commande
      operationId: creer_commande_clients_commande_post
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CommandeCreate'
        required: true
      responses:
        '201':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CommandeRead'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    CommandeCreate:
      properties:
        marchand_id:
          type: string
          format: uuid
          title: Marchand Id
        client_id:
          type: string
          format: uuid
          title: Client Id
        details:
          type: object
          title: Details
      type: object
      required:
        - marchand_id
        - client_id
        - details
      title: CommandeCreate
      example:
        client_id: abf4c1c1-xxxx-xxxx-xxxx-xxxxxxxxxxxx
        details:
          produits:
            - id: 1
              nom: T-shirt en coton
              prix: 29.99
              quantite: 2
        marchand_id: b5cee64b-xxxx-xxxx-xxxx-xxxxxxxxxxxx
    CommandeRead:
      properties:
        id:
          type: string
          format: uuid
          title: Id
        reference:
          type: string
          title: Reference
        statut:
          $ref: '#/components/schemas/StatutCommande'
        total:
          type: number
          title: Total
        articles:
          type: object
          title: Articles
        created_at:
          type: string
          format: date-time
          title: Created At
        marchand_id:
          anyOf:
            - type: string
              format: uuid
            - nullable: true
          title: Marchand Id
        client_id:
          anyOf:
            - type: string
              format: uuid
            - nullable: true
          title: Client Id
      type: object
      required:
        - id
        - reference
        - statut
        - total
        - articles
        - created_at
        - marchand_id
        - client_id
      title: CommandeRead
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    StatutCommande:
      type: string
      enum:
        - en_attente
        - validée
        - annulée
        - en_cours
        - livrée
      title: StatutCommande
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.