AlphaAlpha Docs
API ReferenceCrm opportunity

Get paginated opportunities

Retrieves a paginated list of opportunities

GET
/crm/opportunities/page
AuthorizationBearer <token>

In: header

Query Parameters

pageNumber?integer
Formatint32
pageSize?integer
Formatint32
sortBy?string
direction?string
Value in"ASC" | "DESC"
search?string

Response Body

application/json

application/json

application/json

application/json

application/json

curl -X GET "http://localhost:18080/api/v1/crm/opportunities/page"
{
  "content": [
    {
      "changeOrders": [
        {
          "accessTokenHash": "string",
          "amount": 0.1,
          "approvedAt": "2019-08-24T14:15:22Z",
          "approvedBy": "string",
          "category": "string",
          "createdAt": "2019-08-24T14:15:22Z",
          "createdBy": "string",
          "date": "2019-08-24T14:15:22Z",
          "description": "string",
          "id": "string",
          "rejectedAt": "2019-08-24T14:15:22Z",
          "rejectionReason": "string",
          "sentAt": "2019-08-24T14:15:22Z",
          "sentBy": "string",
          "status": "DRAFT"
        }
      ],
      "created": "2019-08-24T14:15:22Z",
      "createdBy": "string",
      "customerId": "string",
      "description": "string",
      "estimateIds": [
        "string"
      ],
      "events": [
        {
          "authorId": "string",
          "date": "2019-08-24T14:15:22Z",
          "description": "string",
          "id": "string",
          "type": "CREATE"
        }
      ],
      "expectedCloseDate": "2019-08-24T14:15:22Z",
      "fulfillmentDate": "2019-08-24T14:15:22Z",
      "id": "string",
      "invoiceIds": [
        "string"
      ],
      "leadId": "string",
      "name": "string",
      "nextAction": "string",
      "nextActionDueDate": "2019-08-24T14:15:22Z",
      "notes": "string",
      "number": "string",
      "orderDate": "2019-08-24T14:15:22Z",
      "orderId": "string",
      "ownerId": "string",
      "paymentSchedule": [
        {
          "id": "string",
          "includeChangeOrders": true,
          "invoiceId": "string",
          "label": "string",
          "paymentDueDays": 0,
          "percentage": 0.1,
          "relativeDays": 0,
          "status": "PENDING",
          "triggerStatus": "NEW",
          "triggerType": "STATUS_CHANGE",
          "triggeredAt": "2019-08-24T14:15:22Z"
        }
      ],
      "planningBlocks": [
        {
          "endDate": "2019-08-24",
          "id": "string",
          "notes": "string",
          "startDate": "2019-08-24",
          "status": "PLANNED",
          "teamId": "string"
        }
      ],
      "probability": 0,
      "productIds": [
        "string"
      ],
      "questionnaire": [
        {
          "id": "string",
          "label": "string",
          "numberValue": 0.1,
          "options": [
            "string"
          ],
          "photoFileIds": [
            "string"
          ],
          "questionId": "string",
          "required": true,
          "selectedOption": "string",
          "sortOrder": 0,
          "textValue": "string",
          "type": "TEXT"
        }
      ],
      "scheduledEndDate": "2019-08-24",
      "scheduledStartDate": "2019-08-24",
      "source": "string",
      "status": "NEW",
      "subsidiaryId": "string",
      "tags": [
        "string"
      ],
      "teamId": "string",
      "tenantId": "string",
      "updated": "2019-08-24T14:15:22Z",
      "updatedBy": "string",
      "value": 0.1
    }
  ],
  "empty": true,
  "first": true,
  "last": true,
  "number": 0,
  "numberOfElements": 0,
  "pageable": {
    "offset": 0,
    "pageNumber": 0,
    "pageSize": 0,
    "paged": true,
    "sort": {
      "empty": true,
      "sorted": true,
      "unsorted": true
    },
    "unpaged": true
  },
  "size": 0,
  "sort": {
    "empty": true,
    "sorted": true,
    "unsorted": true
  },
  "totalElements": 0,
  "totalPages": 0
}
{
  "detail": "string",
  "time": "2019-08-24T14:15:22Z",
  "title": "string"
}
{
  "detail": "string",
  "time": "2019-08-24T14:15:22Z",
  "title": "string"
}
{
  "detail": "string",
  "time": "2019-08-24T14:15:22Z",
  "title": "string"
}
{
  "detail": "string",
  "time": "2019-08-24T14:15:22Z",
  "title": "string"
}