# 3. Kysely: hae "SatelliteImages"

Hanki "SatelliteImages" määritellyllä pilvikynnyksellä "Field"-kohteelle.

Vihjeet:&#x20;

* Lue kaikki "Farms" jotka ovat "User":n käytettävissä - poista *(*`farmUuids: ["d2bf8ef5-cde0-4500-b931-2edd0fb40781"`*`]`)*. Vastaava työskentely "Fields", "SatelliteImages", "VectorAnalysisMap" kanssa.
* Sallittu `geoMapType` suodata hyväksyttävillä arvoilla: `ALL`, `ORIGIN`, `CROPPED`, `RAW`, `PROCESSED`, `THUMBNAIL`, `CONTRAST`
* Sallitut päivämäärään liittyvät suodattimet: `ennen` ja `jälkeen` jotka kuuluvat [AWSDate](https://docs.aws.amazon.com/appsync/latest/devguide/scalars.html) muotoon. On mahdollista käyttää vain yhtä suodinta. Lisätiedot ovat [TÄSSÄ](/geopard-tutorials/fin/api-dokumentaatio/geopard-api-pyyntojen-yleiskatsaus/37.-kysely-hae-satelliteimages-maaritellylta-aikavalilta.md).
* Sallittu `provider` suodata hyväksyttävillä arvoilla: `PS`, `S2`, `L9`, `L8`, `L7`, `L5`, `L4`
* Sallittu `kynnysarvo` suodatin korostaa pilvikattavuutta: "1" tarkoittaa pilvetöntä, "0" - täysin pilvistä.

{% code overflow="wrap" lineNumbers="true" %}

```graphql
kysely GetFieldSatelliteImagesViaGetFields {
  getFarms (farmUuids: ["<placeholder_of_farm_uuid>"]){
    uuid
    nimi
    fields (fieldUuids: ["<placeholder_of_field_uuid>"]) {
      uuid
      nimi
      satelliteImages (before:"2022-05-01" after: "2022-04-01" provider:S2 threshold:0.83 geoMapType: ORIGIN)  {
        satelliteImage {
          uuid
          acquisitionDate
          provider
        } 
        pilvettömästä-maasta
        geoKartat {
          lyhytNimi
          url
          luokat
          hexVärikoodit
        }
        ndviKeskiarvo
        
        tilastot {
          indeksi
          min
          max
          avg
          mdn
          var
          std
        }
        
        suositeltuMonivuotiseenAnalytiikkaan 
      }
    }
  }
}
```

{% endcode %}

{% code overflow="wrap" lineNumbers="true" %}

```graphql
kysely GetFieldSatelliteImagesViaGetFarms {
  getFields (filter: {fieldUuid: "<placeholder_of_field_uuid>"}) {
    fields {
      uuid
      nimi
      satelliteImages (before:"2022-05-01" after: "2022-04-01" provider:S2 threshold:0.83 geoMapType: ORIGIN)  {
        satelliteImage {
          uuid
          acquisitionDate
          provider
        } 
        pilvettömästä-maasta
        geoKartat {
          lyhytNimi
          url
          luokat
          hexVärikoodit
        }
        ndviKeskiarvo
        
        tilastot {
          indeksi
          min
          max
          avg
          mdn
          var
          std
        } 
        
        suositeltuMonivuotiseenAnalytiikkaan
      }
    }
  }
}
```

{% endcode %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.geopard.tech/geopard-tutorials/fin/api-dokumentaatio/geopard-api-pyyntojen-yleiskatsaus/3.-kysely-hae-satelliteimages.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
