ETASCOM CRM V3 - Documentation API
    Preparing search index...
    • POST(
          request: NextRequest,
      ): Promise<
          | NextResponse<{ error: string }>
          | NextResponse<
              {
                  client: | {
                      code: string;
                      email: string
                      | null;
                      id: string;
                      name: string;
                      phone: string | null;
                      type: string;
                  }
                  | null;
                  createdBy: { email: string; id: string; name: string | null }
                  | null;
                  currency:
                      | { code: string; id: string; name: string; symbol: string }
                      | null;
                  files: {
                      createdAt: Date;
                      filename: string;
                      id: string;
                      key: string;
                      mimetype: string;
                      size: number;
                      url: string;
                  }[];
                  lead: | {
                      code: string;
                      companyName: string
                      | null;
                      email: string | null;
                      id: string;
                      name: string;
                      phone: string | null;
                  }
                  | null;
                  lines: (
                      {
                          finishedProduct: | {
                              code: string;
                              description: (...)
                              | (...);
                              id: string;
                              name: string;
                          }
                          | null;
                          tax: { code: string; id: string; name: string; rate: number }
                          | null;
                      } & {}
                  )[];
                  opportunity: | {
                      id: string;
                      name: string;
                      number: string;
                      stage: BusinessOpportunityStage;
                      status: OpportunityStatus;
                  }
                  | null;
                  seriesPriceTiers: {}[];
              } & {},
          >,
      >

      Parameters

      • request: NextRequest

      Returns Promise<
          | NextResponse<{ error: string }>
          | NextResponse<
              {
                  client: | {
                      code: string;
                      email: string
                      | null;
                      id: string;
                      name: string;
                      phone: string | null;
                      type: string;
                  }
                  | null;
                  createdBy: { email: string; id: string; name: string | null }
                  | null;
                  currency:
                      | { code: string; id: string; name: string; symbol: string }
                      | null;
                  files: {
                      createdAt: Date;
                      filename: string;
                      id: string;
                      key: string;
                      mimetype: string;
                      size: number;
                      url: string;
                  }[];
                  lead: | {
                      code: string;
                      companyName: string
                      | null;
                      email: string | null;
                      id: string;
                      name: string;
                      phone: string | null;
                  }
                  | null;
                  lines: (
                      {
                          finishedProduct: | {
                              code: string;
                              description: (...)
                              | (...);
                              id: string;
                              name: string;
                          }
                          | null;
                          tax: { code: string; id: string; name: string; rate: number }
                          | null;
                      } & {}
                  )[];
                  opportunity: | {
                      id: string;
                      name: string;
                      number: string;
                      stage: BusinessOpportunityStage;
                      status: OpportunityStatus;
                  }
                  | null;
                  seriesPriceTiers: {}[];
              } & {},
          >,
      >