{"id":16748708,"url":"https://github.com/pimdewitte/medalpublicapi","last_synced_at":"2026-02-18T17:32:18.381Z","repository":{"id":91103921,"uuid":"96949107","full_name":"PimDeWitte/MedalPublicApi","owner":"PimDeWitte","description":"Public API endpoints for Medal","archived":false,"fork":false,"pushed_at":"2017-07-20T02:15:33.000Z","size":12,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-18T15:44:25.042Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/PimDeWitte.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2017-07-12T00:40:21.000Z","updated_at":"2017-07-12T00:40:21.000Z","dependencies_parsed_at":"2023-07-01T22:46:08.325Z","dependency_job_id":null,"html_url":"https://github.com/PimDeWitte/MedalPublicApi","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/PimDeWitte/MedalPublicApi","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PimDeWitte%2FMedalPublicApi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PimDeWitte%2FMedalPublicApi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PimDeWitte%2FMedalPublicApi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PimDeWitte%2FMedalPublicApi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/PimDeWitte","download_url":"https://codeload.github.com/PimDeWitte/MedalPublicApi/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PimDeWitte%2FMedalPublicApi/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29587086,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-18T16:55:40.614Z","status":"ssl_error","status_checked_at":"2026-02-18T16:55:37.558Z","response_time":162,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":[],"created_at":"2024-10-13T02:13:27.366Z","updated_at":"2026-02-18T17:32:18.324Z","avatar_url":"https://github.com/PimDeWitte.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"# Basic Calls\nHi everyone, here are some example calls for Medal. All response are given in JSON only. We will add more functionality soon (such as being able to upvote inside discord, submitting clips, and seeing results from a specific discord channel. For now you'll have to use MedalBot for these features.)\n\n## Look at the examples!\nWe have javascript examples and java examples so you can just drag and drop the code :-)\n\n## Sync your game database with ours\n\n\nGet started by syncing your local games with ours. You can do this by syncing with our categories endpoint.\n\nFor example: Do a request to https://api.gomedal.com/categories and you'll receive a JSON array of categories like this:\n\n```json\n[{\"categoryId\":39,\"categoryName\":\"Battlefield\",\"categoryThumbnail\":\"https://static-cdn.jtvnw.net/ttv-boxart/Battlefield%201-52x72.jpg\",\"categoryBackground\":\"https://static-cdn.jtvnw.net/ttv-boxart/Battlefield%201-52x72.jpg\",\"categoryFollowers\":52,\"categoryPublishers\":1,\"isFeatured\":1},{\"categoryId\":41,\"categoryName\":\"PUBG\",\"categoryThumbnail\":\"https://static-cdn.jtvnw.net/ttv-boxart/PLAYERUNKNOWN%27S%20BATTLEGROUNDS-272x380.jpg\",\"categoryBackground\":\"https://static-cdn.jtvnw.net/ttv-boxart/PLAYERUNKNOWN%27S%20BATTLEGROUNDS-272x380.jpg\",\"categoryFollowers\":104,\"categoryPublishers\":1,\"isFeatured\":1}]\n```\n\nSimple save the categoryName and the categoryId to a local array and save it. You'll need it later.\n\n\n## Now you can make API calls\n\nAfter you've synced the games, you can request trending clips. This is how it works:\n\nSend a GET request to \n\n```\nhttps://api.gomedal.com/botclips\n```\n\n### Here are some examples:\n\nReturn 1 random clip (useful for .randomclip command):\n```\nhttps://api.gomedal.com/botclips?random=true\u0026limit=1\n```\n\nReturn 1 random PUBG clip (useful for .randomclip command):\n```\nhttps://api.gomedal.com/botclips?random=true\u0026categoryId=41\n```\n\nReturn the top 10 PUBG clips of that day:\n```\nhttps://api.gomedal.com/botclips?categoryId=41\u0026limit=10\n```\n\nNote here that 41 is the categoryId that you also used when you synced your games with ours. This way, if a user types \".topclips PUBG\" you can check which categoryName matches with the user input (and maybe write some exceptions) and assign the right categoryId.\n\nReturn the global top 50 of that day\n```\nhttps://api.gomedal.com/botclips?limit=50\n```\n\nIt returns a JSON array with content objects\n\n```json\n[{\"contentId\":493654,\"contentType\":15,\"categoryId\":41,\"contentTitle\":\"Josh_OG Shooting threw smoke? Explain?\",\"contentUrl\":\"https://gomedal.com/clips/493654\",\"thumbnail1080p\":\"https://s3.amazonaws.com/gomedal2/img/thumbnail-k0lezoeret3kyjjr-1080p.jpg\",\"thumbnail720p\":\"https://s3.amazonaws.com/gomedal2/img/thumbnail-k0lezoeret3kyjjr-720p.jpg\",\"thumbnail480p\":\"https://s3.amazonaws.com/gomedal2/img/thumbnail-k0lezoeret3kyjjr-480p.jpg\",\"thumbnail360p\":\"https://s3.amazonaws.com/gomedal2/img/thumbnail-k0lezoeret3kyjjr-360p.jpg\",\"thumbnail240p\":\"https://s3.amazonaws.com/gomedal2/img/thumbnail-k0lezoeret3kyjjr-240p.jpg\",\"thumbnail144p\":\"https://s3.amazonaws.com/gomedal2/img/thumbnail-k0lezoeret3kyjjr-144p.jpg\",\"videoLengthSeconds\":31,\"likes\":1,\"views\":9,\"thumbnailUrl\":\"https://s3.amazonaws.com/gomedal2/img/thumbnail-k0lezoeret3kyjjr-1080p.jpg\",\"credits\":\"Medal Discord,https://discord.gg/KEuwx6s,Discord\"},{\"contentId\":493659,\"contentType\":15,\"categoryId\":41,\"contentTitle\":\"Can I flip your car?\",\"contentUrl\":\"https://gomedal.com/clips/493659\",\"thumbnail1080p\":\"https://s3.amazonaws.com/gomedal2/img/thumbnail-s1a8urla2izl88q3-1080p.jpg\",\"thumbnail720p\":\"https://s3.amazonaws.com/gomedal2/img/thumbnail-s1a8urla2izl88q3-720p.jpg\",\"thumbnail480p\":\"https://s3.amazonaws.com/gomedal2/img/thumbnail-s1a8urla2izl88q3-480p.jpg\",\"thumbnail360p\":\"https://s3.amazonaws.com/gomedal2/img/thumbnail-s1a8urla2izl88q3-360p.jpg\",\"thumbnail240p\":\"https://s3.amazonaws.com/gomedal2/img/thumbnail-s1a8urla2izl88q3-240p.jpg\",\"thumbnail144p\":\"https://s3.amazonaws.com/gomedal2/img/thumbnail-s1a8urla2izl88q3-144p.jpg\",\"videoLengthSeconds\":5,\"likes\":1,\"views\":4,\"thumbnailUrl\":\"https://s3.amazonaws.com/gomedal2/img/thumbnail-s1a8urla2izl88q3-1080p.jpg\",\"credits\":\"Medal Discord,https://discord.gg/KEuwx6s,Discord\"}]\n\n```\n\n\nThis should be everything you need to implement .randomclip, .randomclip {GAME_NAME}, .topclips and .topclips {GAME_NAME}.\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpimdewitte%2Fmedalpublicapi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpimdewitte%2Fmedalpublicapi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpimdewitte%2Fmedalpublicapi/lists"}