{"id":20915105,"url":"https://github.com/microcks/microcks-backstage-provider","last_synced_at":"2026-03-02T14:42:45.039Z","repository":{"id":65177437,"uuid":"585161053","full_name":"microcks/microcks-backstage-provider","owner":"microcks","description":"A provider for Backstage.io allowing to synchronize API entities from Microcks to Backstage","archived":false,"fork":false,"pushed_at":"2025-09-26T09:46:40.000Z","size":2154,"stargazers_count":9,"open_issues_count":0,"forks_count":6,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-10-01T18:36:07.332Z","etag":null,"topics":["api","backstage","backstage-plugin","contract-testing","microcks","mocking"],"latest_commit_sha":null,"homepage":"https://microcks.io","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/microcks.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY-INSIGHTS.yml","support":null,"governance":"GOVERNANCE.md","roadmap":"ROADMAP.md","authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":"MAINTAINERS.md","copyright":null,"agents":null,"dco":null,"cla":null},"funding":{"github":"microcks","patreon":null,"open_collective":"microcks","ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"custom":null}},"created_at":"2023-01-04T13:26:21.000Z","updated_at":"2025-09-26T09:46:37.000Z","dependencies_parsed_at":"2024-02-18T04:30:47.231Z","dependency_job_id":"25e47715-883f-44b7-8df5-9e7646e0e258","html_url":"https://github.com/microcks/microcks-backstage-provider","commit_stats":{"total_commits":52,"total_committers":5,"mean_commits":10.4,"dds":0.5384615384615384,"last_synced_commit":"dddd7e6dd614c0f4c1aed561f15f17c75342f660"},"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"purl":"pkg:github/microcks/microcks-backstage-provider","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/microcks%2Fmicrocks-backstage-provider","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/microcks%2Fmicrocks-backstage-provider/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/microcks%2Fmicrocks-backstage-provider/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/microcks%2Fmicrocks-backstage-provider/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/microcks","download_url":"https://codeload.github.com/microcks/microcks-backstage-provider/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/microcks%2Fmicrocks-backstage-provider/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":277892367,"owners_count":25895604,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-01T02:00:09.286Z","response_time":88,"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":["api","backstage","backstage-plugin","contract-testing","microcks","mocking"],"created_at":"2024-11-18T16:13:02.171Z","updated_at":"2025-10-07T03:29:24.675Z","avatar_url":"https://github.com/microcks.png","language":"TypeScript","funding_links":["https://github.com/sponsors/microcks","https://opencollective.com/microcks"],"categories":[],"sub_categories":[],"readme":"# Microcks Backstage provider\n\n[![GitHub Workflow Status](https://img.shields.io/github/actions/workflow/status/microcks/microcks-backstage-provider/build-verify.yml?logo=github\u0026style=for-the-badge)](https://github.com/microcks/microcks-backstage-provider/actions)\n[![Version](https://img.shields.io/npm/v/@microcks/microcks-backstage-provider?color=blue\u0026style=for-the-badge)]((https://search.maven.org/artifact/io.github.microcks/microcks))\n[![License](https://img.shields.io/github/license/microcks/microcks?style=for-the-badge\u0026logo=apache)](https://www.apache.org/licenses/LICENSE-2.0)\n[![Project Chat](https://img.shields.io/badge/discord-microcks-pink.svg?color=7289da\u0026style=for-the-badge\u0026logo=discord)](https://microcks.io/discord-invite/)\n[![Artifact HUB](https://img.shields.io/endpoint?url=https://artifacthub.io/badge/repository/microcks\u0026style=for-the-badge)](https://artifacthub.io/packages/search?repo=microcks)\n[![CNCF Landscape](https://img.shields.io/badge/CNCF%20Landscape-5699C6?style=for-the-badge\u0026logo=cncf)](https://landscape.cncf.io/?item=app-definition-and-development--application-definition-image-build--microcks)\n\nThis is a plugin for synchronizing Microcks content into [Backstage.io](https://backstage.io/) catalog.\n\nThe `microcks-backstage-provider` has a special entity provider for discovering catalog [API entities](https://backstage.io/docs/features/software-catalog/system-model#api) defined in one or many Microcks instances. If you're using Microcks to discover APIs from your Git repositories, auto-publish smart mock endpoints and realize contract testing of your components, this provider can synchronize the API definitions from Microcks into your Backstage intance.\n\n## Build Status\n\nLatest released version is `0.0.7`.\n\nCurrent development version is `0.0.8-SNAPSHOT`.\n\n#### Fossa license and security scans\n\n[![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2Fmicrocks%2Fmicrocks-backstage-provider.svg?type=shield\u0026issueType=license)](https://app.fossa.com/projects/git%2Bgithub.com%2Fmicrocks%2Fmicrocks-backstage-provider?ref=badge_shield\u0026issueType=license)\n[![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2Fmicrocks%2Fmicrocks-backstage-provider.svg?type=shield\u0026issueType=security)](https://app.fossa.com/projects/git%2Bgithub.com%2Fmicrocks%2Fmicrocks-backstage-provider?ref=badge_shield\u0026issueType=security)\n[![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2Fmicrocks%2Fmicrocks-backstage-provider.svg?type=small)](https://app.fossa.com/projects/git%2Bgithub.com%2Fmicrocks%2Fmicrocks-backstage-provider?ref=badge_small)\n\n#### OpenSSF best practices on Microcks core\n\n[![CII Best Practices](https://bestpractices.coreinfrastructure.org/projects/7513/badge)](https://bestpractices.coreinfrastructure.org/projects/7513)\n[![OpenSSF Scorecard](https://api.securityscorecards.dev/projects/github.com/microcks/microcks/badge)](https://securityscorecards.dev/viewer/?uri=github.com/microcks/microcks)\n\n## Community\n\n* [Documentation](https://microcks.io/documentation/tutorials/getting-started/)\n* [Microcks Community](https://github.com/microcks/community) and community meeting\n* Join us on [Discord](https://microcks.io/discord-invite/), on [GitHub Discussions](https://github.com/orgs/microcks/discussions) or [CNCF Slack #microcks channel](https://cloud-native.slack.com/archives/C05BYHW1TNJ)\n\nTo get involved with our community, please make sure you are familiar with the project's [Code of Conduct](./CODE_OF_CONDUCT.md).\n\n## Versions\n\n| Basckstage Client | Microcks Backstage provider Version |\n|-------------------|------------------|\n| `\u003e= 1.43`         | `0.0.7` and +    |\n| `\u003e= 1.31 \u0026\u0026 \u003c1.43`| `0.0.6` and +    |\n| `\u003c 1.31`          | `0.0.5`          |\n\n## Screenshots\n\nYour Services and API from different Microcks instances can be discovered and imported into your Backstage catalog.\n\n\u003ca href=\"./assets/discovery-and-import.png\"\u003e\n  \u003cimg src=\"./assets/discovery-and-import.png\" width=\"600\"\u003e \n\u003c/a\u003e\n\n\nLabels on your API in Microcks are be translated onto Backstage systems and owners. The plugin add links to access the API mock endpoints and conformance tests results. \n\n\u003ca href=\"./assets/api-properties-mapping.png\"\u003e\n  \u003cimg src=\"./assets/api-properties-mapping.png\" width=\"600\"\u003e \n\u003c/a\u003e\n\n## Install\n\nAfter having created a new backstage app like described in Backstage.io' [Getting Started](https://backstage.io/docs/getting-started/#create-your-backstage-app), enter the app directory and run this command to add the Microcks Entity provider as a new backend plugin:\n\n```sh\nyarn --cwd packages/backend add @microcks/microcks-backstage-provider@^0.0.7\n```\n\n## Configure\n\nMicrocks Backstage provider allows configuration of one or many providers using the `app-config.yaml` configuration file of Backstage. Use a `microcksApiEntity` marker to start configuring them.\n\nEach children key (here `dev` in the following sample) configures a provider for a specific `lifecyle` phase of your Entities so you may discover `API` entities from different Microcks instances.\n\nAt your configuration, you add a provider config per liefcycle:\n\n```yaml\n# app-config.yaml\n\ncatalog:\n  providers:\n    microcksApiEntity:\n      dev:\n        baseUrl: https://microcks.acme.com\n        serviceAccount: microcks-serviceaccount\n        serviceAccountCredentials: ab54d329-e435-41ae-a900-ec6b3fe15c54\n        systemLabel: domain\n        ownerLabel: team \n        addLabels: false # optional; copy any other labels from Microcks in Backstage catalog - default is true\n        addOpenAPIServerUrl: true # optional; add a server in OpenAPI spec to point to Microcks sandbox URL - default is false\n        schedule: # optional; same options as in TaskScheduleDefinition\n          # supports cron, ISO duration, \"human duration\" as used in code\n          frequency: { minutes: 2 }\n          # supports ISO duration, \"human duration\" as used in code\n          timeout: { minutes: 1 }  \n```\n\nConfiguration is pretty straightforward but your may check Microcks documentation on [Service Accounts](https://microcks.io/documentation/automating/service-account/) for details.\n\nOnce you've done that, you'll also need to declare the Microcks as a backend module or an available entity provider. This operation differs depending on the version of Backstage you're using.\n\n### For Backstage versions with the new Backend system\n\n\u003e Typically for application created via the CLI starting with Backstage `1.24`\n\nYou'll need to add the Microcks backend module in the `packages/backend/src/index.ts` file, before the `backend.start()` directive. Use this snippet below:\n\n```ts\n// microcks catalog provider\nbackend.add(import('@microcks/microcks-backstage-provider'));\n```\n\n### For Backstage versions with the old Backend plugin system\n\nYou need add the segment below to `packages/backend/src/plugins/catalog.ts`:\n\n```ts\n/* packages/backend/src/plugins/catalog.ts */\n\nimport { MicrocksApiEntityProvider } from '@microcks/microcks-backstage-provider';\n\n[...]\n  const builder = await CatalogBuilder.create(env);\n\n  /** ... other processors and/or providers ... */\n  builder.addEntityProvider(\n    MicrocksApiEntityProvider.fromConfig(env.config, {\n      logger: env.logger,\n      scheduler: env.scheduler\n    }),\n  );\n\n  const { processingEngine, router } = await builder.build();\n[...]\n``` \n\n## Troubleshoot\n\nAfter having started your Backstage app, you should see some lines like those below in logs:\n\n```log\n[1] 2023-01-04T16:07:47.630Z catalog info Keycloak authentication is not enabled, using a fake token. type=plugin target=MicrocksApiEntityProvider:dev\n[1] 2023-01-04T16:07:47.699Z catalog info Discovered ApiEntity API Pastry - 2.0 - 2.0.0 type=plugin target=MicrocksApiEntityProvider:dev\n[1] 2023-01-04T16:07:47.708Z catalog info Discovered ApiEntity Account Service - 1.1.0 type=plugin target=MicrocksApiEntityProvider:dev\n[1] 2023-01-04T16:07:47.712Z catalog info Discovered ApiEntity HelloService - v1 type=plugin target=MicrocksApiEntityProvider:dev\n[1] 2023-01-04T16:07:47.728Z catalog info Discovered ApiEntity User signed-up API - 0.1.1 type=plugin target=MicrocksApiEntityProvider:dev\n[1] 2023-01-04T16:07:47.734Z catalog info Discovered ApiEntity User signed-up API - 0.1.20 type=plugin target=MicrocksApiEntityProvider:dev\n[1] 2023-01-04T16:07:47.740Z catalog info Discovered ApiEntity User signed-up API - 0.1.30 type=plugin target=MicrocksApiEntityProvider:dev\n[1] 2023-01-04T16:07:47.745Z catalog info Discovered ApiEntity User signed-up Avro API - 0.1.2 type=plugin target=MicrocksApiEntityProvider:dev\n[1] 2023-01-04T16:07:47.749Z catalog info Applying the mutation with 7 entities type=plugin target=MicrocksApiEntityProvider:dev\n```\n\n## Build and release\n\nAfter a fresh `git clone`, you can install dependencies, compile typescript and build a new distribution with those commands:\n\n```sh\n$ yarn install \u0026\u0026 yarn tsc \u0026\u0026 yarn export-dynamic \u0026\u0026 yarn run build\n```\n\nWhen publishing a release withe the `release` GitHub Action, generating the SBOM from Yarn files fails because of unresolved transitive dependencies. So we included `package-lock.json` and generate the SBOM with the `--package-lock-only` flag.\n\n\u003e So, whenever you update a dependency in `package.json` and then `yarn.lock`, please ensure that you also update `package-lock.json` otherwise the next release will fail!\n\n## Develop locally\n\nAfter having created a new backstage app like described in Backstage.io' [Getting Started](https://backstage.io/docs/getting-started/#create-your-backstage-app), just edit the `packages/backend/src/plugins/catalog.ts` file and apply same configuration as above insdtallation directive but with relative path to your local clone of this repository:\n\n```ts\n/* packages/backend/src/plugins/catalog.ts */\n\nimport { MicrocksApiEntityProvider } from '../../../../../github/microcks-backstage-provider';\n```\n\nJust launch your local backstage app using `yarn dev` at the root folder level.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmicrocks%2Fmicrocks-backstage-provider","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmicrocks%2Fmicrocks-backstage-provider","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmicrocks%2Fmicrocks-backstage-provider/lists"}