API สาธารณะของเราช่วยให้คุณย่อ URL แบบโปรแกรมได้ ไม่ต้องใช้คีย์ API หรือการตรวจสอบสิทธิ์
ส่งวัตถุเดี่ยวหรืออาเรย์ของวัตถุเพื่อย่อ URL
{
"domain": "clc.is",
"target_url": "https://example.com",
"slug": "custom", // optional
"expired_url": "https://expired.example.com", // optional
"expired_hours": 48 // optional (0 = no expiration)
}
{
"input": { ... },
"slug": "custom",
"url": "https://clc.is/custom",
"is_generated": false
}
ส่งคืนอาเรย์ของโดเมนที่ใช้ได้สำหรับการย่อ URL
["clc.is", "alt1.com", "alt2.com"]
409 Conflict
— หาก slug ถูกใช้งานแล้ว400 Bad Request
— ข้อความหรือพารามิเตอร์ไม่ถูกต้องสำหรับการส่ง URL ได้สูงสุด 5000 รายการในครั้งเดียว ใช้หน้า การประมวลผลจำนวนมาก หรือส่งอาเรย์ของรายการไปที่ /api/links