# Taisly API Dokumantasyonu - **OpenAPI Version:** `3.1.0` - **API Version:** `1.0.0` # Taisly API Dokumantasyonu Taisly API, basit API anahtari kimlik dogrulamasi kullanarak video paylasimini ve yeniden paylasimi birden fazla sosyal medya platformunda otomatiklestirmenizi saglar. ## Ozellikler - Videolari ayni anda birden fazla platforma yukleme ve paylasma - Bir platformdan digerlerine otomatik yeniden paylasim ayarlama - Gonderileri daha sonra yayinlanacak sekilde planlama - Bagli sosyal medya hesaplarini yonetme - Gonderi gecmisini ve durumunu izleme ## Gereksinimler - **Plan**: STARTER, INFLUENCER veya PRO (API anahtarlari FREE planda mevcut degildir) - **API Anahtari**: Panonuzdan adresinde olusturun - **HTTPS**: Tum API istekleri HTTPS kullanmalidir ## Istek Limitleri | Plan | Saatlik Istek | | ---------- | ------------- | | STARTER | 50 | | INFLUENCER | 200 | | PRO | 1000 | Limiti astiginizda, kac saniye beklemeniz gerektigini gosteren `retryAfter` alaniyla birlikte 429 hatasi alirsiniz. ## Guvenlik Icin En Iyi Uygulamalar 1. API anahtarlarini asla surum kontrolune commit etmeyin 2. Anahtarlari ortam degiskenlerinde saklayin 3. Ele gecirildiyse hemen yeniden olusturun 4. Sadece HTTPS kullanin ## Video Gereksinimleri - **Format**: MP4, MOV veya diger yaygin video formatlari - **Boyut**: Maksimum 500MB - **Sure**: 3-90 saniye - **Yon**: Dikey (9:16) ## Hizli Baslangic Ornegi ```bash # 1. Bagli platformlarinizi alin curl -X GET https://app.taisly.com/api/private/platform/platforms \ -H "Authorization: Bearer taisly_your_api_key_here" # 2. Bir video yukleyin curl -X POST https://app.taisly.com/api/private/post \ -H "Authorization: Bearer taisly_your_api_key_here" \ -F "video=@/path/to/video.mp4" \ -F "platforms=[\"platform_id_1\"]" \ -F "description=Yeni videoma bakin!" # 3. Gonderi gecmisini kontrol edin curl -X GET https://app.taisly.com/api/private/post/history \ -H "Authorization: Bearer taisly_your_api_key_here" ``` ## Python Ornegi ```python import requests API_KEY = 'taisly_your_api_key_here' BASE_URL = 'https://app.taisly.com/api/private' headers = { 'Authorization': f'Bearer {API_KEY}' } # Platformlari al response = requests.get(f'{BASE_URL}/platform/platforms', headers=headers) platforms = response.json()['data'] print(f"Bagli platformlar: {len(platforms)}") # Video yukle files = {'video': open('video.mp4', 'rb')} data = { 'platforms': str([platforms[0]['_id']]), 'description': 'Video aciklamam' } response = requests.post(f'{BASE_URL}/post', headers=headers, files=files, data=data) print(response.json()) ``` ## Servers - **URL:** `https://app.taisly.com/api/private` - **Description:** Uretim sunucusu ## Operations ### API Anahtari Bilgilerini Al - **Method:** `GET` - **Path:** `/user/api-key` - **Tags:** API Key Management Mevcut API anahtariniz hakkinda bilgi alin. #### Responses ##### Status: 200 ###### Content-Type: application/json ##### Status: 403 ###### Content-Type: application/json ##### Status: 500 ###### Content-Type: application/json ### API Anahtari Olustur - **Method:** `POST` - **Path:** `/user/api-key/generate` - **Tags:** API Key Management Yeni bir API anahtari olusturun veya zaten varsa yeniden olusturun. **ONEMLI**: - Tam API anahtari yalnizca bir kez gosterilir. Guvenli bir sekilde saklayin. - Yeniden olusturursaniz eski anahtar hemen gecersiz kilinir. #### Responses ##### Status: 200 ###### Content-Type: application/json ##### Status: 500 ###### Content-Type: application/json ### API Anahtarini Iptal Et - **Method:** `POST` - **Path:** `/user/api-key/revoke` - **Tags:** API Key Management Mevcut API anahtarinizi hemen iptal edin. Bu anahtari kullanan tum istekler basarisiz olur. #### Responses ##### Status: 200 ###### Content-Type: application/json ##### Status: 403 ###### Content-Type: application/json ##### Status: 500 ###### Content-Type: application/json ### Bagli Platformlari Al - **Method:** `GET` - **Path:** `/platform/platforms` - **Tags:** Platforms Hesabiniza bagli tum sosyal medya hesaplarini alin. #### Responses ##### Status: 200 ###### Content-Type: application/json ##### Status: 401 ###### Content-Type: application/json ##### Status: 403 ###### Content-Type: application/json ##### Status: 500 ###### Content-Type: application/json ### Gonderi Olustur - **Method:** `POST` - **Path:** `/post` - **Tags:** Posts Bir videoyu bir veya daha fazla bagli platforma yukleyin. **Video Gereksinimleri:** - Format: MP4, MOV veya diger yaygin video formatlari - Boyut: Maksimum 500MB - Sure: 3-90 saniye - Yon: Dikey (9:16) **Planlama:** - Planli paylasim icin `scheduled` degerini milisaniye cinsinden Unix zaman damgasi olarak gonderin (planlamak istemiyorsaniz bu parametreyi atlayin) #### Request Body ##### Content-Type: multipart/form-data - **`platforms` (required)** `array` — Kimlik listesi **Items:** `string` - **`video` (required)** `string`, format: `binary` — - **`description`** `string` - **`previewTime`** `number` — Kucuk resim olusturma icin saniye cinsinden zaman damgasi (varsayilan: 0) - **`scheduled`** `string` **Example:** ```json { "video": {}, "platforms": [ "" ], "description": "", "previewTime": 1, "scheduled": "" } ``` #### Responses ##### Status: 200 ###### Content-Type: application/json ##### Status: 401 ###### Content-Type: application/json ##### Status: 403 ###### Content-Type: application/json ##### Status: 500 ###### Content-Type: application/json ### Gonderi Gecmisini Al - **Method:** `GET` - **Path:** `/post/history` - **Tags:** Posts Her platform icin durum bilgileriyle birlikte gonderi gecmisinizi alin. **Sayfalama**: - Sayfalama icin `page` parametresini kullanin (sayfa basina 10 oge) - Veya tarih araligi filtrelemesi icin `startTime` ve `endTime` kullanin (eslesen tum gonderileri dondurur) **Durum Degerleri**: - PENDING: Gonderi kuyrukta - SUCCESS: Basariyla paylasildi - FAILED: Gonderi basarisiz oldu (hata kodu icin message alanini kontrol edin) #### Responses ##### Status: 200 ###### Content-Type: application/json ##### Status: 401 ###### Content-Type: application/json ##### Status: 500 ###### Content-Type: application/json ### Planli Gonderiyi Iptal Et - **Method:** `GET` - **Path:** `/post/cancelSchedule` - **Tags:** Posts Daha sonra yayinlanmak uzere planlanan bir gonderiyi iptal edin. Gonderi kalici olarak silinir. #### Responses ##### Status: 200 ###### Content-Type: application/json ##### Status: 401 ###### Content-Type: application/json ##### Status: 500 ###### Content-Type: application/json ### Yeniden Paylasim Yapilandirmalarini Al - **Method:** `GET` - **Path:** `/reposts` - **Tags:** Reposts Yapilandirilmis tum otomatik yeniden paylasim kurallarini alin. Bir 'from' platformuna gonderi yayinladiginizda, icerik otomatik olarak tum 'to' platformlarina yeniden paylasilir. #### Responses ##### Status: 200 ###### Content-Type: application/json ##### Status: 401 ###### Content-Type: application/json ##### Status: 500 ###### Content-Type: application/json ### Yeniden Paylasim Yapilandirmasi Ekle - **Method:** `POST` - **Path:** `/repost/add` - **Tags:** Reposts Bir platformdan digerlerine otomatik yeniden paylasim yapilandirin. **Nasil calisir**: - 'from' platformuna icerik paylastiginizda, tum 'to' platformlarina otomatik olarak yeniden paylasilir **Not**: Dairesel bagimliliklar engellenir. B->A zaten varsa A->B olusturamazsiniz. #### Request Body ##### Content-Type: application/json - **`from` (required)** `string` — Platform kimligi - **`to` (required)** `array` — Platform kimlikleri listesi **Items:** `string` **Example:** ```json { "from": "", "to": [ "" ] } ``` #### Responses ##### Status: 200 ###### Content-Type: application/json ##### Status: 400 ###### Content-Type: application/json ##### Status: 401 ###### Content-Type: application/json ##### Status: 500 ###### Content-Type: application/json ### Yeniden Paylasim Yapilandirmasini Sil - **Method:** `POST` - **Path:** `/repost/delete` - **Tags:** Reposts Otomatik yeniden paylasim kuralini kaldirin. Kaynak platformdaki gelecekteki gonderiler artik otomatik olarak yeniden paylasilmaz. #### Request Body ##### Content-Type: application/json - **`id` (required)** `string` **Example:** ```json { "id": "" } ``` #### Responses ##### Status: 200 ###### Content-Type: application/json ##### Status: 401 ###### Content-Type: application/json ##### Status: 500 ###### Content-Type: application/json ### Yeniden Paylasim Yapilandirmasini Duraklat/Surdur - **Method:** `POST` - **Path:** `/repost/pause` - **Tags:** Reposts Otomatik yeniden paylasimi gecici olarak duraklatin veya surdurun. Yapilandirmayi silmeden yeniden paylasimi gecici olarak durdurmak istediginizde kullanislidir. #### Request Body ##### Content-Type: application/json - **`id` (required)** `string` - **`pause` (required)** `boolean` - **`isPaused`** `boolean` **Example:** ```json { "id": "", "pause": true, "isPaused": true } ``` #### Responses ##### Status: 200 ###### Content-Type: application/json ##### Status: 401 ###### Content-Type: application/json ##### Status: 500 ###### Content-Type: application/json