Passport Photo Requirements — Agent Skill
Passport Photo Requirements — Agent Skill
A ready-to-use skill for AI agents to help with passport photo requirements and generation.
What This Skill Does
-
Requirements lookup — Get exact passport photo specifications for any country
-
Photo editing — Transform a regular photo into a compliant passport photo using AI
Getting Started
-
Sign up at aipass.one ($1 free credit on signup)
-
Create an API key at the Developer Dashboard
-
Set
$AIPASS_API_KEYin your environment -
Use the skill in the
skillContentfield
Quick Example
curl -s -X POST https://aipass.one/apikey/v1/chat/completions \
-H "Authorization: Bearer $AIPASS_API_KEY" \
-H "Content-Type: application/json" \
-d '{"model":"openai/gpt-4.1-mini","messages":[{"role":"system","content":"You are a passport photo expert. Provide exact specifications."},{"role":"user","content":"UK passport photo requirements"}]}'
Models Used
-
Text (requirements):
openai/gpt-4.1-mini -
Image editing:
gemini/gemini-3-pro-image-preview
Related
Skill File
---
name: passport-photo-assistant
description: Get passport photo requirements by country and edit photos to be compliant using AI Pass API.
version: 1.0.0
---
# Passport Photo Assistant Skill
Help users understand passport photo requirements and generate compliant photos.
## Requirements
- AI Pass API key (create at https://aipass.one/panel/developer.html)
- Set as environment variable: `$AIPASS_API_KEY`
## Usage
### Get Requirements (text completion)
```bash
curl -s -X POST https://aipass.one/apikey/v1/chat/completions \
-H "Authorization: Bearer $AIPASS_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "openai/gpt-4.1-mini",
"messages": [
{"role": "system", "content": "You are a passport photo requirements expert. Given a country, provide exact photo specifications: dimensions, background color, head size, file format, and common rejection reasons. Be precise and practical."},
{"role": "user", "content": "US passport photo requirements"}
]
}'
```
Response: `r.choices[0].message.content`
### Edit Photo to Be Compliant (image editing)
```bash
# Requires base64 encoded image
IMAGE_B64=$(base64 -w0 photo.jpg)
curl -s -X POST https://aipass.one/apikey/v1/chat/completions \
-H "Authorization: Bearer $AIPASS_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "gemini/gemini-3-pro-image-preview",
"messages": [
{"role": "user", "content": [
{"type": "text", "text": "Transform this into a compliant US passport photo: white background, 2x2 inches, head centered, neutral expression, even lighting."},
{"type": "image_url", "image_url": {"url": "data:image/jpeg;base64,'$IMAGE_B64'"}}
]}
]
}'
```
### Python
```python
import requests, os, base64
def get_photo_requirements(country):
r = requests.post(
"https://aipass.one/apikey/v1/chat/completions",
headers={
"Authorization": f"Bearer {os.environ['AIPASS_API_KEY']}",
"Content-Type": "application/json"
},
json={
"model": "openai/gpt-4.1-mini",
"messages": [
{"role": "system", "content": "You are a passport photo requirements expert. Provide exact specifications."},
{"role": "user", "content": f"{country} passport photo requirements"}
]
}
)
return r.json()["choices"][0]["message"]["content"]
# Example
print(get_photo_requirements("United Kingdom"))
```
## Supported Countries
US, UK, EU/Schengen, Canada, Australia, India, China, Japan, and most others.
## Notes
- Text queries (requirements lookup): uses `openai/gpt-4.1-mini`
- Image editing (photo transformation): uses `gemini/gemini-3-pro-image-preview`
- Pay as you go. $1 free credit on signup at https://aipass.one
- Create API key at https://aipass.one/panel/developer.html
## Related
- App: https://aipass.one/apps/passport-photo
- User guide: https://aipass.one/blog/ai-passport-photo-maker-online
- Dev tutorial: https://aipass.one/blog/build-passport-photo-app-tutorial
Download Skill File