add-endpoint — community add-endpoint, switcher_webapi, community, ide skills

v1.0.0

About this Skill

Perfect for Python-based AI Agents needing to control and query local Switcher smart devices through containerized access Step-by-step guide for adding a new API endpoint to switcher_webapi. Use when adding new device functionality or API routes.

TomerFi TomerFi
[0]
[0]
Updated: 3/12/2026

Killer-Skills Review

Decision support comes first. Repository text comes second.

Reviewed Landing Page Review Score: 9/11

Killer-Skills keeps this page indexable because it adds recommendation, limitations, and review signals beyond the upstream repository text.

Original recommendation layer Concrete use-case guidance Explicit limitations and caution Quality floor passed for review Locale and body language aligned
Review Score
9/11
Quality Score
51
Canonical Locale
en
Detected Body Locale
en

Perfect for Python-based AI Agents needing to control and query local Switcher smart devices through containerized access Step-by-step guide for adding a new API endpoint to switcher_webapi. Use when adding new device functionality or API routes.

Core Value

Empowers agents to add new device control functionality and expose aioswitcher API methods, leveraging Python's async capabilities and RESTful API endpoints like GET, POST, PATCH, and DELETE

Ideal Agent Persona

Perfect for Python-based AI Agents needing to control and query local Switcher smart devices through containerized access

Capabilities Granted for add-endpoint

Adding new device control functionality
Exposing new aioswitcher API methods
Creating new query endpoints

! Prerequisites & Limits

  • Requires modification of app/webapp.py
  • Limited to Switcher smart devices
  • Python 3.x compatibility required

Source Boundary

The section below is imported from the upstream repository and should be treated as secondary evidence. Use the Killer-Skills review above as the primary layer for fit, risk, and installation decisions.

After The Review

Decide The Next Action Before You Keep Reading Repository Material

Killer-Skills should not stop at opening repository instructions. It should help you decide whether to install this skill, when to cross-check against trusted collections, and when to move into workflow rollout.

Labs Demo

Browser Sandbox Environment

⚡️ Ready to unleash?

Experience this Agent in a zero-setup browser environment powered by WebContainers. No installation required.

Boot Container Sandbox

FAQ & Installation Steps

These questions and steps mirror the structured data on this page for better search understanding.

? Frequently Asked Questions

What is add-endpoint?

Perfect for Python-based AI Agents needing to control and query local Switcher smart devices through containerized access Step-by-step guide for adding a new API endpoint to switcher_webapi. Use when adding new device functionality or API routes.

How do I install add-endpoint?

Run the command: npx killer-skills add TomerFi/switcher_webapi/add-endpoint. It works with Cursor, Windsurf, VS Code, Claude Code, and 19+ other IDEs.

What are the use cases for add-endpoint?

Key use cases include: Adding new device control functionality, Exposing new aioswitcher API methods, Creating new query endpoints.

Which IDEs are compatible with add-endpoint?

This skill is compatible with Cursor, Windsurf, VS Code, Trae, Claude Code, OpenClaw, Aider, Codex, OpenCode, Goose, Cline, Roo Code, Kiro, Augment Code, Continue, GitHub Copilot, Sourcegraph Cody, and Amazon Q Developer. Use the Killer-Skills CLI for universal one-command installation.

Are there any limitations for add-endpoint?

Requires modification of app/webapp.py. Limited to Switcher smart devices. Python 3.x compatibility required.

How To Install

  1. 1. Open your terminal

    Open the terminal or command line in your project directory.

  2. 2. Run the install command

    Run: npx killer-skills add TomerFi/switcher_webapi/add-endpoint. The CLI will automatically detect your IDE or AI agent and configure the skill.

  3. 3. Start using the skill

    The skill is now active. Your AI agent can use add-endpoint immediately in the current project.

Upstream Repository Material

The section below is imported from the upstream repository and should be treated as secondary evidence. Use the Killer-Skills review above as the primary layer for fit, risk, and installation decisions.

Upstream Source

add-endpoint

Install add-endpoint, an AI agent skill for AI agent workflows and automation. Review the use cases, limitations, and setup path before rollout.

SKILL.md
Readonly
Upstream Repository Material
The section below is imported from the upstream repository and should be treated as secondary evidence. Use the Killer-Skills review above as the primary layer for fit, risk, and installation decisions.
Supporting Evidence

Adding a New Endpoint

When to Use

  • Adding new device control functionality
  • Exposing new aioswitcher API methods
  • Creating new query endpoints

Step 1: Define Endpoint Constant

In app/webapp.py, add the endpoint path constant (around line 54-71):

python
1ENDPOINT_YOUR_ENDPOINT = "/switcher/your_endpoint"

Step 2: Create Handler Function

Add the async handler with the appropriate decorator:

python
1@routes.get(ENDPOINT_YOUR_ENDPOINT) # or .post, .patch, .delete 2async def your_endpoint(request: web.Request) -> web.Response: 3 """Describe what this endpoint does.""" 4 device_type = DEVICES[request.query[KEY_TYPE]] 5 if KEY_LOGIN_KEY in request.query: 6 login_key = request.query[KEY_LOGIN_KEY] 7 else: 8 login_key = "00" 9 async with SwitcherApi( 10 device_type, request.query[KEY_IP], request.query[KEY_ID], login_key 11 ) as swapi: 12 result = await swapi.your_method() 13 return web.json_response(_serialize_object(result))

Step 3: Add Tests

In app/tests/test_web_app.py, add test cases:

python
1@mark.parametrize("url", [ 2 "/switcher/your_endpoint?type=plug&id=ab1c2d&ip=1.2.3.4", 3 "/switcher/your_endpoint?type=plug&id=ab1c2d&ip=1.2.3.4&key=18", 4]) 5async def test_successful_your_endpoint_get_request(api_client, url): 6 with patch("app.webapp.SwitcherApi") as mock_api: 7 mock_api.return_value.__aenter__.return_value.your_method = AsyncMock( 8 return_value=expected_response 9 ) 10 resp = await api_client.get(url) 11 assert resp.status == 200

Step 4: Update Documentation

Create or update the relevant docs file in docs/:

  • Add endpoint to the appropriate endpoints_*.md file
  • Include method, path, description, and query parameters

Step 5: Run Tests

Use the /test command to run tests with coverage.

Reference

Look at existing endpoints for patterns:

  • get_state - Simple GET returning device state
  • turn_on - POST with optional body parameters
  • control_breeze_device - PATCH with complex body handling

Related Skills

Looking for an alternative to add-endpoint or another community skill for your workflow? Explore these related open-source skills.

View All

openclaw-release-maintainer

Logo of openclaw
openclaw

Your own personal AI assistant. Any OS. Any Platform. The lobster way. 🦞

333.8k
0
AI

widget-generator

Logo of f
f

Generate customizable widget plugins for the prompts.chat feed system

149.6k
0
AI

flags

Logo of vercel
vercel

The React Framework

138.4k
0
Browser

pr-review

Logo of pytorch
pytorch

Tensors and Dynamic neural networks in Python with strong GPU acceleration

98.6k
0
Developer