From 4ad77092d07159ebcf5ada40e49aa17fade1fe04 Mon Sep 17 00:00:00 2001 From: xnacly Date: Wed, 30 Dec 2020 23:07:11 +0100 Subject: [PATCH] Update README.md --- README.md | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/README.md b/README.md index c7095453..3439a95d 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,27 @@ # discord-cdn cdn for discord clone + +## Endpoints: + +### /external +#### POST +``` +Content-Type: application/json + +body: +{"url": URL} // "https://discord.com" +``` +##### Returns: +Content-Type: application/json +```ts +{ + "id": string, // "aHR0cHM6Ly9kaXNjb3JkLmNvbQ==" + "ogTitle": string, // "Discord | Your Place to Talk and Hang Out" + "ogDescription": string, // "Discord is the easiest way to talk over voice, video, and text. Talk, chat, hang out, and stay close with your friends and communities." + "cachedImage": string, // "/external/aHR0cHM6Ly9kaXNjb3JkLmNvbQ==/discord.png" + "ogUrl": string, // "https://discord.com/" + "ogType": string // "website" +} +``` +### /external/:id/:filename +#### GET