API
Projects

5. Projects

To retrieve list of projects to be shown on dashboard, you have to run following query:

query Projects($filters: ProjectFiltersInput) {
  projects(filters: $filters) {
    data {
      id
      attributes {
        flags
        title
        status
        shortDescription
        cover {
          data {
            attributes {
              url
            }
          }
        }
        sale {
          annualValueAdded
          distributed
          totalShares
          tokenPrice
        }
      }
    }
  }
}

with filter values:

{
  "filters": {
    "status": {
      "in": [
        "UPCOMING",
        "ACTIVE",
        "CLOSED"
      ]
    },
    "locale": {
      "eq": "en"
    },
    "platform": {
      "eq": "RENTINVESTO"
    }
  }
}

Authorization: Bearer ACCESS_TOKEN

Response:

{
  "data": {
    "projects": {
      "data": [
        {
          "id": "1",
          "attributes": {
            "flags": {},
            "title": "test",
            "status": "UPCOMING",
            "shortDescription": "testestsetsetetete",
            "cover": {
              "data": {
                "attributes": {
                  "url": "https://.../uploads/image.png"
                }
              }
            },
            "sale": {
              "annualValueAdded": 2,
              "distributed": 1,
              "totalShares": 5,
              "tokenPrice": 6
            }
          }
        }
      ]
    }
  }
}