Skip to content

Instantly share code, notes, and snippets.

@dvirsegal
Created April 5, 2026 16:44
Show Gist options
  • Select an option

  • Save dvirsegal/fec553ba2c0db1d268d6c7510d57d0d3 to your computer and use it in GitHub Desktop.

Select an option

Save dvirsegal/fec553ba2c0db1d268d6c7510d57d0d3 to your computer and use it in GitHub Desktop.
Israel Postal Code Lookup - Agent Skill for finding Israeli zip codes (מיקוד)
name israel-postal-code
description Look up Israeli postal/zip codes (מיקוד) from an address using an Israel Post style postal code lookup API. Use when the user provides an Israeli address (city, street, house number) and wants the postal code / zip code / מיקוד. Supports Hebrew and English address input. Triggers: מיקוד, postal code, zip code, Israel address, israeli post, דואר ישראל.
metadata
author version
dvir
1.0

Israel Postal Code Lookup

When to Use This Skill

Use this skill when the user provides an Israeli address and wants to find the postal code (מיקוד).
The user may provide the address in Hebrew or English, as a full string or as separate fields (city, street, house number).

API Details

This skill calls a postal-code lookup API that behaves like the Israel Post zip code service.

Expected headers:

  • Content-Type: application/json
  • Ocp-Apim-Subscription-Key: <SUBSCRIPTION_KEY>

Use a subscription key that is configured outside this file.

Example base URL:

  • https://<postal-api-host>

Lookup Flow

Step 1: Parse the Address

Extract from the user's input:

  • City/Settlement (יישוב)
  • Street (רחוב), if provided
  • House number (מספר בית), if provided

If the user gives a free-text address like "דיזנגוף 50 תל אביב", parse it into components.

Step 2: Find the City

POST https://<postal-api-host>/mypost-zip/GetCities
Content-Type: application/json
Ocp-Apim-Subscription-Key: <SUBSCRIPTION_KEY>

{
  "CityStartsWith": "CITY_NAME",
  "Lang": "HE"
}

Typical response fields:

  • id – city ID
  • n – city name
  • divided – true/false
  • zip – postal code when divided is false

If divided is false, use zip and stop.
If multiple cities match, pick the best match or ask the user to clarify.

Step 3: Find the Street (if city is divided)

POST https://<postal-api-host>/mypost-zip/GetStreets
Content-Type: application/json
Ocp-Apim-Subscription-Key: <SUBSCRIPTION_KEY>

{
  "CityID": "CITY_ID",
  "CityName": "",
  "SearchMode": "ID-StartsWith",
  "StartsWith": "STREET_NAME",
  "Lang": "HE"
}

Response fields:

  • id – street ID
  • n – street name

If multiple streets match, pick the exact match when possible or ask for clarification.
If the user did not provide a street for a divided city, ask for the street name.

Step 4: Search for the Zip Code

POST https://<postal-api-host>/mypost-zip/SearchZip
Content-Type: application/json
Ocp-Apim-Subscription-Key: <SUBSCRIPTION_KEY>

{
  "CityID": "CITY_ID",
  "StreetID": "STREET_ID",
  "House": "HOUSE_NUMBER",
  "Entry": "",
  "ByMaanimID": true
}

If there is no house number, send "House": "".

Typical response fields:

  • zip – postal code
  • cityname – confirmed city name
  • msgtype"address", "noentrances", "unitedtown", "notfound"
  • messageResult – description text

Output Format

If a result is found:

המיקוד עבור [address] הוא: ZIPCODE

If no result is found:

לא נמצא מיקוד עבור הכתובת שהוזנה.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment