# WeatherNow — Weather, Marine & Aviation Conditions API (`kopachelli/weathernow`) Actor

Give it a list of "latitude,longitude" locations or ICAO airport codes. One bulk run returns one dataset item per value: current conditions, 24-hour forecast and marine data for locations; METAR and TAF for airports.

- **URL**: https://apify.com/kopachelli/weathernow.md
- **Developed by:** [Khristian Kopachelli](https://apify.com/kopachelli) (community)
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.60 / 1,000 location conditions

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

**Give it a list of locations ("latitude,longitude") and ICAO airport codes. For each
location it returns current conditions, a 24-hour forecast and marine data where
available; for each airport it returns the METAR and TAF reports — one dataset
item per value, in batch.**

> **Air quality is not covered.** No keyless globally available AQI source permits
> commercial use, so `aqi` is always `null`. Marine data exists only where MET
> Norway's ocean forecast covers the point (Northern/Western European waters).

> **Not for safety-critical decisions.** Aviation and marine data are informational
> only. Always check official sources (METAR/TAF issuers, coast guards, national
> weather services) before any operational decision.

### What it is for

- **Batch condition checks.** One run answers "what is the weather and sea state at
  these points?" for a whole list of coordinates.
- **Airport weather in bulk.** METAR and TAF for a list of ICAO codes — for route
  planning tools, dispatch systems, monitoring dashboards.
- **Monitoring and alerting pipelines.** Scheduled runs produce a dataset of current
  conditions that downstream tools can diff or alert on.

### Input

| Field | Default | Meaning |
|---|---|---|
| `values` (required) | — | The places to check, one per item. A location is `"latitude,longitude"`; an airport is its four-letter ICAO code. |
| `maxItems` | 1000 | The run stops after this many values. The largest value is 100,000. There is no "unlimited". |

### Example input

```json
{
    "values": ["50.0755,14.4378", "LKPR"],
    "maxItems": 1000
}
```

A minimal example — the schema prefill (12 example values) is what Apify's daily test uses.

### Output

#### Dataset: one item per value

```json
{
    "value": "LKPR",
    "detectedType": "metar",
    "valid": true,
    "detail": "Aviation reports found for LKPR (aviationweather.gov (NOAA)).",
    "metar": {
        "icao": "LKPR",
        "fetchedAtUtc": "2026-11-18T00:00:01Z",
        "source": "aviationweather.gov (NOAA)",
        "metar": "LKPR 180000Z 27010KT 9999 FEW040 05/M02 Q1020",
        "observedAtUtc": "2026-11-18T00:00:00Z",
        "stale": false,
        "taf": null
    }
}
```

| Field | Meaning |
|---|---|
| `value` | The value exactly as given (trimmed). |
| `detectedType` | `location`, `metar` or `unknown`. |
| `valid` | Whether conditions or reports were found; `null` when the check could not answer. |
| `detail` | Why the value produced data or not. |
| `location` | Present for locations: coordinates, freshness, current conditions, 24-hour forecast, marine data. `aqi` is always `null` — air quality is not covered. |
| `metar` | Present for ICAO codes: the METAR and TAF texts, observation time and staleness flag. |

#### Key-value store

`OUTPUT` — a summary of the run: values received, items pushed, counts by kind, and why the run stopped.

### Limits and honesty

- Every item names its `source` and timestamps; `stale: true` marks data older than
  the freshness window.
- Values that match no known kind get `valid: null` and are not charged.
- A value whose upstream fails is reported honestly — never invented.
- Timeouts, retries and the spending limit are bounded; a restarted run resumes from
  its checkpoint without double-charging.

### Cost

Pay per event: one event per location checked, one per airport checked. See the
Actor's pricing tab for the current prices.

The Actor identifies itself with the User-Agent
`WeatherNow/1.0 (+https://apify.com/kopachelli/weathernow)` on every upstream request.

# Actor input Schema

## `values` (type: `array`):

The places to check, one per item. A location is written as "latitude,longitude" (for example "50.0755,14.4378"); an airport is its four-letter ICAO code (for example "LKPR").

## `maxItems` (type: `integer`):

The run stops after this many values. There is no "unlimited": the largest value is 100,000.

## Actor input object example

```json
{
  "values": [
    "50.0755,14.4378",
    "48.8566,2.3522",
    "51.5074,-0.1278",
    "40.7128,-74.0060",
    "35.6762,139.6503",
    "-33.8688,151.2093",
    "LKPR",
    "EDDF",
    "KLAX",
    "EGLL",
    "OMDB",
    "YSSY"
  ],
  "maxItems": 1000
}
```

# Actor output Schema

## `items` (type: `string`):

One item per input value: the value, its detected kind, the check result and the detail.

## `summary` (type: `string`):

How the run ended: values received and processed, why it stopped.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "values": [
        "50.0755,14.4378",
        "48.8566,2.3522",
        "51.5074,-0.1278",
        "40.7128,-74.0060",
        "35.6762,139.6503",
        "-33.8688,151.2093",
        "LKPR",
        "EDDF",
        "KLAX",
        "EGLL",
        "OMDB",
        "YSSY"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("kopachelli/weathernow").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "values": [
        "50.0755,14.4378",
        "48.8566,2.3522",
        "51.5074,-0.1278",
        "40.7128,-74.0060",
        "35.6762,139.6503",
        "-33.8688,151.2093",
        "LKPR",
        "EDDF",
        "KLAX",
        "EGLL",
        "OMDB",
        "YSSY",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("kopachelli/weathernow").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "values": [
    "50.0755,14.4378",
    "48.8566,2.3522",
    "51.5074,-0.1278",
    "40.7128,-74.0060",
    "35.6762,139.6503",
    "-33.8688,151.2093",
    "LKPR",
    "EDDF",
    "KLAX",
    "EGLL",
    "OMDB",
    "YSSY"
  ]
}' |
apify call kopachelli/weathernow --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,kopachelli/weathernow"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/3sfBDI3GfTQZUuMeU/builds/OIJiFRggSTpz4bRMN/openapi.json
