{"id":15287595,"url":"https://github.com/dankeboy36/vscode-arduino-api","last_synced_at":"2026-07-11T16:00:40.492Z","repository":{"id":165262549,"uuid":"640580406","full_name":"dankeboy36/vscode-arduino-api","owner":"dankeboy36","description":"Type-only Arduino API contract for Arduino IDE 2.x and BoardLab extensions","archived":false,"fork":false,"pushed_at":"2026-02-24T17:04:11.000Z","size":527,"stargazers_count":5,"open_issues_count":2,"forks_count":0,"subscribers_count":4,"default_branch":"main","last_synced_at":"2026-02-24T20:54:53.151Z","etag":null,"topics":["arduino","arduino-ide","theia-ide","vscode","vscode-extension"],"latest_commit_sha":null,"homepage":"https://github.com/dankeboy36/vscode-arduino-api/blob/main/docs/interfaces/ArduinoContext.md","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dankeboy36.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2023-05-14T15:05:37.000Z","updated_at":"2026-02-24T17:05:47.000Z","dependencies_parsed_at":"2023-12-27T21:18:38.182Z","dependency_job_id":"b8542f92-6038-47aa-a3e8-27293921287c","html_url":"https://github.com/dankeboy36/vscode-arduino-api","commit_stats":null,"previous_names":["dankeboy36/vscode-arduino-ide-api"],"tags_count":10,"template":false,"template_full_name":null,"purl":"pkg:github/dankeboy36/vscode-arduino-api","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dankeboy36%2Fvscode-arduino-api","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dankeboy36%2Fvscode-arduino-api/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dankeboy36%2Fvscode-arduino-api/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dankeboy36%2Fvscode-arduino-api/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dankeboy36","download_url":"https://codeload.github.com/dankeboy36/vscode-arduino-api/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dankeboy36%2Fvscode-arduino-api/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":35367446,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-07-11T02:00:05.354Z","response_time":104,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["arduino","arduino-ide","theia-ide","vscode","vscode-extension"],"created_at":"2024-09-30T15:32:21.461Z","updated_at":"2026-07-11T16:00:40.487Z","avatar_url":"https://github.com/dankeboy36.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# vscode-arduino-api\n\n[![Build](https://github.com/dankeboy36/vscode-arduino-api/actions/workflows/ci.yml/badge.svg?branch=main)](https://github.com/dankeboy36/vscode-arduino-api/actions/workflows/ci.yml)\n![NPM Version](https://img.shields.io/npm/v/vscode-arduino-api)\n\nThis is a types-only npm package providing the ArduinoContext API contract for Arduino IDE 2.x and BoardLab tools. The npm tarball ships no runtime JavaScript; runtime providers are supplied by the host environment.\n\n## What this is\n\n- A compile-time contract for the `ArduinoContext` API.\n- The npm package contains no runtime JavaScript.\n- The runtime provider is host-specific (IDE2 built-in or BoardLab in VS Code).\n\nThe primary, current target is Visual Studio Code with BoardLab as the runtime provider. The IDE2 lane (0.1.x) is legacy and receives compatibility-only updates.\n\n## Runtime providers\n\n- Visual Studio Code: provider is BoardLab (`dankeboy36.boardlab`). Tools should depend on BoardLab for runtime access.\n- Arduino IDE 2.x: provider is bundled in the IDE. It does not download this extension from Open VSX or the Visual Studio Code Marketplace.\n\n## Compatibility lanes\n\n- BoardLab lane: `vscode-arduino-api@latest` (0.2.x+) for Visual Studio Code + BoardLab.\n- IDE2 lane: `vscode-arduino-api@ide2` (0.1.x) for Arduino IDE 2.x tools ([deprecated API surface](https://github.com/dankeboy36/vscode-arduino-api/blob/0.1.2/src/api.ts)).\n\n## Install types\n\nThis package provides only TypeScript types. Install the appropriate version depending on your target environment:\n\n### Visual Studio Code + BoardLab tools\n\n```shell\nnpm install -D vscode-arduino-api\n```\n\nBoardLab provides the runtime API in Visual Studio Code and must be present as an extension dependency.\n\n### Arduino IDE 2.x tools (deprecated API)\n\n![NPM Version (with ide2 tag)](https://img.shields.io/npm/v/vscode-arduino-api/ide2)\n\n```shell\nnpm install -D vscode-arduino-api@ide2\n```\n\n### Additional type dependencies\n\nThese peer dependencies are required for type resolution. Install them if they are not already present in your extension development setup:\n\n```shell\nnpm install -D ardunno-cli boards-list @types/vscode\n```\n\nOnly one provider is active at a time. Choose the provider that matches your target. If you target IDE2 only, use the IDE2 provider ID and do not include BoardLab.\n\n## Resolve provider at runtime\n\n```ts\nimport * as vscode from 'vscode'\nimport type { ArduinoContext } from 'vscode-arduino-api'\n\n// Visual Studio Code + BoardLab target.\nconst PROVIDERS = ['dankeboy36.boardlab'] as const\n\n// Arduino IDE 2.x target: use this instead of the BoardLab provider.\n// const PROVIDERS = ['dankeboy36.vscode-arduino-api'] as const\n\nexport function tryGetArduinoContext(): ArduinoContext | undefined {\n  for (const id of PROVIDERS) {\n    const ext = vscode.extensions.getExtension(id)\n    const api = ext?.exports as ArduinoContext | undefined\n    if (api) return api\n  }\n  return undefined\n}\n```\n\n## Publishing guidance\n\n- Visual Studio Code extension: add `extensionDependencies` on `dankeboy36.boardlab`.\n- This repo publishes npm types only; it does not build or publish a VSIX artifact.\n\n## Dist-tags and releases\n\n- IDE2 lane: publish 0.1.x patch releases and apply the `ide2` dist-tag, which always points to the latest 0.1.x version compatible with Arduino IDE 2.x.\n- BoardLab lane: `latest` remains 0.2.x+.\n\n```shell\nnpm dist-tag ls vscode-arduino-api\n```\n\n## API reference\n\nSee the generated API docs in [`docs/README.md`](./docs/README.md).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdankeboy36%2Fvscode-arduino-api","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdankeboy36%2Fvscode-arduino-api","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdankeboy36%2Fvscode-arduino-api/lists"}