{"id":20768008,"url":"https://github.com/human-connection/embed-api","last_synced_at":"2025-04-30T11:22:40.897Z","repository":{"id":91368657,"uuid":"126733442","full_name":"Human-Connection/Embed-API","owner":"Human-Connection","description":"API Service for fetching URL Information like images, icons, descriptions etc. thourgh OpenGraph, oEmbed and other standards.","archived":false,"fork":false,"pushed_at":"2020-01-20T04:25:17.000Z","size":283,"stargazers_count":10,"open_issues_count":19,"forks_count":5,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-03-30T15:46:55.635Z","etag":null,"topics":["oembed","opengraph"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","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/Human-Connection.png","metadata":{"files":{"readme":"README.md","changelog":null,"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}},"created_at":"2018-03-25T19:42:10.000Z","updated_at":"2024-05-31T01:32:17.000Z","dependencies_parsed_at":null,"dependency_job_id":"a0ef45ef-7386-4db6-99c5-87bcc2441053","html_url":"https://github.com/Human-Connection/Embed-API","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Human-Connection%2FEmbed-API","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Human-Connection%2FEmbed-API/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Human-Connection%2FEmbed-API/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Human-Connection%2FEmbed-API/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Human-Connection","download_url":"https://codeload.github.com/Human-Connection/Embed-API/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251689011,"owners_count":21627817,"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","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":["oembed","opengraph"],"created_at":"2024-11-17T11:34:29.835Z","updated_at":"2025-04-30T11:22:40.883Z","avatar_url":"https://github.com/Human-Connection.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Embed API\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://travis-ci.org/Human-Connection/Embed-API\"\u003e\u003cimg src=\"https://travis-ci.org/Human-Connection/Embed-API.svg?branch=master\" alt=\"Build Status\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n\u003e URL Embed API with Caching\n\n## About\n\nThis API uses [Metaphor](https://www.npmjs.com/package/metaphor) for fetching URL data from multiple sources.\n\n## How to use this image\n\nMake sure you have installed [docker](https://www.docker.com/community-edition).\n\n### Running locally\n\nTo test this service on you local machine, simply run:\n\n```bash\ndocker run --rm --name embed-api humanconnection/embed-api:latest\n```\n\nYou can use docker-compose, too:\n```sh\ndocker-compose up\n# wait until the services are up\ncurl --header \"authentication: embedapitoken\" \"http://localhost:3050/embeds?url=http://www.human-connection.org/\"\n```\n\n### Running in Production\n\nMake sure you provide an unique API Key as well as a mongoDB user and password on your production server:\n\n```bash\ndocker run --rm --name embed-api -e \"EMBED_API_TOKEN=MYSUPERSECRETSTRING\" -e \"EMBED_API_MONGO_USER=MONGOUSER\" -e \"EMBED_API_MONGO_PASS=MONGOPASS\" humanconnection/embed-api:latest\n```\n\n## Development\n\n1. Make sure you have [NodeJS](https://nodejs.org/), [yarn](https://yarnpkg.com) and [mongoDB](https://www.mongodb.com/download-center#community) installed.\n2. Install your dependencies\n\n    ```\n    cd path/to/embed-api; yarn install\n    ```\n\n3. Start your app\n\n    ```\n    yarn dev\n    ```\n\n4. Get URL Information\n   \n   ```\n   http://localhost:3050/embeds?url=http://www.human-connection.org/\n   ```\n\n5. Do something creative with the following output\n   (More information here: [Metaphor](https://www.npmjs.com/package/metaphor))\n\n   ```\n   {\n        site_name: 'YouTube',\n        url: 'https://www.youtube.com/watch?v=cWDdd5KKhts',\n        title: 'Cheese Shop Sketch - Monty Python\\'s Flying Circus',\n        image: { url: 'https://i.ytimg.com/vi/cWDdd5KKhts/maxresdefault.jpg' },\n        description: 'Subscribe to the Official Monty Python Channel here - http://smarturl.it/SubscribeToPython Cleese plays an erudite customer attempting to purchase some chees...',\n        type: 'video',\n        video: [\n            {\n                url: 'https://www.youtube.com/embed/cWDdd5KKhts',\n                type: 'text/html',\n                width: '480',\n                height: '360'\n            },\n            {\n                url: 'https://www.youtube.com/v/cWDdd5KKhts?version=3\u0026autohide=1',\n                type: 'application/x-shockwave-flash',\n                width: '480',\n                height: '360',\n                tag: ['Monty Python', 'Python (Monty) Pictures Limited', 'Comedy', 'flying circus', 'monty pythons flying circus', 'john cleese', 'micael palin', 'eric idle', 'terry jones', 'graham chapman', 'terry gilliam', 'funny', 'comedy', 'animation', '60s animation', 'humor', 'humour', 'sketch show', 'british comedy', 'cheese shop', 'monty python cheese', 'cheese shop sketch', 'cleese cheese', 'cheese']\n            }\n        ],\n        thumbnail: {\n            url: 'https://i.ytimg.com/vi/cWDdd5KKhts/hqdefault.jpg',\n            width: 480,\n            height: 360\n        },\n        embed: {\n            type: 'video',\n            height: 344,\n            width: 459,\n            html: '\u003ciframe width=\"459\" height=\"344\" src=\"https://www.youtube.com/embed/cWDdd5KKhts?feature=oembed\" frameborder=\"0\" allowfullscreen\u003e\u003c/iframe\u003e'\n        },\n        app: {\n            iphone: {\n                name: 'YouTube',\n                id: '544007664',\n                url: 'vnd.youtube://www.youtube.com/watch?v=cWDdd5KKhts\u0026feature=applinks'\n            },\n            ipad: {\n                name: 'YouTube',\n                id: '544007664',\n                url: 'vnd.youtube://www.youtube.com/watch?v=cWDdd5KKhts\u0026feature=applinks'\n            },\n            googleplay: {\n                name: 'YouTube',\n                id: 'com.google.android.youtube',\n                url: 'https://www.youtube.com/watch?v=cWDdd5KKhts'\n            }\n        },\n        player: {\n            url: 'https://www.youtube.com/embed/cWDdd5KKhts',\n            width: '480',\n            height: '360'\n        },\n        twitter: { site_username: '@youtube' },\n        icon: {\n            '32': 'https://s.ytimg.com/yts/img/favicon_32-vfl8NGn4k.png',\n            '48': 'https://s.ytimg.com/yts/img/favicon_48-vfl1s0rGh.png',\n            '96': 'https://s.ytimg.com/yts/img/favicon_96-vfldSA3ca.png',\n            '144': 'https://s.ytimg.com/yts/img/favicon_144-vflWmzoXw.png',\n            smallest: 'https://s.ytimg.com/yts/img/favicon_32-vfl8NGn4k.png'\n        },\n        preview: '\u003chtml\u003e\u003chead\u003e\u003ctitle\u003eCheese Shop Sketch - Monty Python\\'s Flying Circus\u003c/title\u003e\u003c/head\u003e\u003cbody\u003e\u003cdiv class=\\'metaphor-embed\\'\u003e\u003cdiv class=\\'metaphor-embed-header\\'\u003e\u003cimg class=\"metaphor-embed-header-icon\" src=\"https://s.ytimg.com/yts/img/favicon_32-vfl8NGn4k.png\"/\u003e\u003cdiv class=\"metaphor-embed-header-site\"\u003eYouTube\u003c/div\u003e\u003ca class =\"metaphor-embed-header-link\" href=\"https://www.youtube.com/watch?v=cWDdd5KKhts\"\u003e\u003cdiv class=\"metaphor-embed-header-title\"\u003eCheese Shop Sketch - Monty Python\\'s Flying Circus\u003c/div\u003e\u003c/a\u003e\u003c/div\u003e\u003cdiv class=\\'metaphor-embed-body\\'\u003e\u003cdiv class=\"metaphor-embed-body-description\"\u003eSubscribe to the Official Monty Python Channel here - http://smarturl.it/SubscribeToPython Cleese plays an erudite customer attempting to purchase some chees...\u003c/div\u003e\u003cimg class=\"metaphor-embed-body-image\" src=\"https://i.ytimg.com/vi/cWDdd5KKhts/hqdefault.jpg\"/\u003e\u003c/div\u003e\u003c/div\u003e\u003c/body\u003e\u003c/html\u003e',\n        sources: ['ogp', 'resource', 'oembed', 'twitter']\n    }\n    ```\n## Testing\n\nSimply run `yarn test` and all your tests in the `test/` directory will be run.\n\n### Testing with docker-compose\n\nYou can run eslint and mocha with:\n```\n- docker-compose run --rm embed-api yarn run eslint\n- docker-compose run --rm embed-api yarn run mocha\n```\n\n## License\n\nCopyright (c) 2018\nGrzegorz Leoniec\n\nLicensed under the [MIT license](LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhuman-connection%2Fembed-api","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhuman-connection%2Fembed-api","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhuman-connection%2Fembed-api/lists"}