ETASCOM CRM V3 - Documentation API
    Preparing search index...
    • POST(
          request: NextRequest,
      ): Promise<
          | NextResponse<{ error: string }>
          | NextResponse<
              {
                  currency: {}
                  | null;
                  invoice:
                      | {
                          client: { code: string; id: string; name: string };
                          id: string;
                          number: string;
                          totalAmount: number;
                      }
                      | null;
                  supplierInvoice: | {
                      id: string;
                      number: string;
                      supplier: { code: string; id: string; name: string };
                      totalAmount: number;
                  }
                  | null;
              } & {},
          >,
      >

      Parameters

      • request: NextRequest

      Returns Promise<
          | NextResponse<{ error: string }>
          | NextResponse<
              {
                  currency: {}
                  | null;
                  invoice:
                      | {
                          client: { code: string; id: string; name: string };
                          id: string;
                          number: string;
                          totalAmount: number;
                      }
                      | null;
                  supplierInvoice: | {
                      id: string;
                      number: string;
                      supplier: { code: string; id: string; name: string };
                      totalAmount: number;
                  }
                  | null;
              } & {},
          >,
      >

      /api/accounting/payments: post: tags: [Accounting, Payments] summary: Enregistre un nouveau paiement description: Enregistre un paiement pour une facture client ou fournisseur requestBody: required: true content: application/json: schema: type: object required: - amount - paymentDate - paymentMethod properties: invoiceId: type: string supplierInvoiceId: type: string amount: type: number currencyId: type: string exchangeRate: type: number paymentDate: type: string format: date paymentMethod: type: string reference: type: string bankAccount: type: string notes: type: string responses: 201: description: Paiement créé avec succès 400: description: Données invalides 401: description: Non autorisé 500: description: Erreur serveur