Developers

Referência de API para desenvolvedores

An API key is required for requests to be processed by the system. Once a user registers, an API key is automatically generated for this user.

Começando

Uma chave de API é necessária para que as solicitações sejam processadas pelo sistema. Depois que um usuário se registra, uma chave de API é gerada automaticamente para esse usuário. A chave de API deve ser enviada com cada solicitação (veja o exemplo completo abaixo). Se a chave de API não for enviada ou tiver expirado, ocorrerá um erro. Certifique-se de manter sua chave de API em segredo para evitar abusos.

Autenticação

Para autenticar com o sistema de API, você precisa enviar sua chave de API como um token de autorização com cada solicitação. Você pode ver o código de exemplo abaixo.

curl --location --request POST 'https://urlkai.com/api/account' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \ 

מגבלת טקסונים

Nossa API tem um limitador de taxa para proteger contra picos de solicitações para maximizar sua estabilidade. Nosso limitador de taxa está limitado a 30 solicitações por 1 minuto. אנא שימו לב כי המחיר עשוי להשתנות בהתאם לתכנית המנויים.

Vários cabeçalhos serão enviados juntamente com a resposta e estes podem ser examinados para determinar várias informações sobre a solicitação.

X-RateLimit-Limit: 30X-RateLimit-Remaining: 29X-RateLimit-Reset: TIMESTAMP

Tratamento de respostas

Todas as respostas da API são retornadas no formato JSON por padrão. Para converter isso em dados utilizáveis, a função apropriada precisará ser usada de acordo com o idioma. Em PHP, a função json_decode() pode ser usada para converter os dados em um objeto (padrão) ou um array (defina o segundo parâmetro como true). É muito importante verificar a chave de erro, pois ela fornece informações sobre se houve ou não um erro. Você também pode verificar o código do cabeçalho.

{
    "error": 1,
    "message": "An error occurred"
}

חשבון

קבל חשבון

קיבל https://urlkai.com/api/account

כדי לקבל מידע על החשבון, אתה יכול לשלוח בקשה לנקודת קצה זו והיא תחזיר נתונים בחשבון.

curl --location --request GET 'https://urlkai.com/api/account' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \

Resposta do servidor

{
    "error": 0,
    "data": {
        "id": 1,
        "email": "[email protected]",
        "username": "sampleuser",
        "avatar": "https:\/\/domain.com\/content\/avatar.png",
        "status": "pro",
        "expires": "2022-11-15 15:00:00",
        "registered": "2020-11-10 18:01:43"
    }
}

עדכון חשבון

שים https://urlkai.com/api/account/update

כדי לעדכן מידע על החשבון, אתה יכול לשלוח בקשה לנקודת קצה זו והיא תעדכן נתונים בחשבון.

curl --location --request PUT 'https://urlkai.com/api/account/update' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
--data-raw '{
    "email": "[email protected]",
    "password": "NewPassword1"
}'

Resposta do servidor

{
    "error": 0,
    "message": "Account has been successfully updated."
}

קמפניאס

רשימות קמפיינים

קיבל https://urlkai.com/api/campaigns?limit=2&page=1

כדי להעביר את הקמפיינים שלך דרך ה-API, אתה יכול להשתמש בנקודת קצה זו. באפשרותך גם לסנן נתונים (ראה טבלה לקבלת מידע נוסף).

Parâmetro Descrição
גבול (אופציונלי) תוצאת נתונים לכל עמוד
דף (אופציונלי) בקשה לדף נוכחי
curl --location --request GET 'https://urlkai.com/api/campaigns?limit=2&page=1' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \

Resposta do servidor

{
    "error": "0",
    "data": {
        "result": 2,
        "perpage": 2,
        "currentpage": 1,
        "nextpage": 1,
        "maxpage": 1,
        "campaigns": [
            {
                "id": 1,
                "name": "Sample Campaign",
                "public": false,
                "rotator": false,
                "list": "https:\/\/domain.com\/u\/admin\/list-1"
            },
            {
                "id": 2,
                "domain": "Facebook Campaign",
                "public": true,
                "rotator": "https:\/\/domain.com\/r\/test",
                "list": "https:\/\/domain.com\/u\/admin\/test-2"
            }
        ]
    }
}

Crie uma campanha

הצבה https://urlkai.com/api/campaign/add

ניתן להוסיף קמפיין באמצעות נקודת קצה זו.

Parâmetro Descrição
שם (אופציונלי) שם הקמפיין
סלאג (אופציונלי) שבלול מסובב
ציבור (אופציונלי) גישה
curl --location --request POST 'https://urlkai.com/api/campaign/add' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
--data-raw '{
    "name": "New Campaign",
    "slug": "new-campaign",
    "public": true
}'

Resposta do servidor

{
    "error": 0,
    "id": 3,
    "domain": "New Campaign",
    "public": true,
    "rotator": "https:\/\/domain.com\/r\/new-campaign",
    "list": "https:\/\/domain.com\/u\/admin\/new-campaign-3"
}
הצבה https://urlkai.com/api/campaign/:campaignid/assign/:linkid

ניתן להקצות קישור קצר לקמפיין באמצעות נקודת קצה זו. נקודת הקצה דורשת את מזהה הקמפיין ואת מזהה הקישור הקצר.

curl --location --request POST 'https://urlkai.com/api/campaign/:campaignid/assign/:linkid' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \

Resposta do servidor

{
    "error": 0,
    "message": "Link successfully added to the campaign."
}

Atualizar campanha

שים https://urlkai.com/api/campaign/:id/update

כדי לעדכן קמפיין, עליך לשלוח נתונים חוקיים ב-JSON באמצעות בקשת PUT. יש לשלוח את הנתונים כגוף הגולמי של בקשתך כפי שמוצג להלן. הדוגמה שלהלן מציגה את כל הפרמטרים שבאפשרותך לשלוח, אך אינך נדרש לשלוח את כולם (ראה טבלה למידע נוסף).

Parâmetro Descrição
שם (חובה) שם הקמפיין
סלאג (אופציונלי) שבלול מסובב
ציבור (אופציונלי) גישה
curl --location --request PUT 'https://urlkai.com/api/campaign/:id/update' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
--data-raw '{
    "name": "Twitter Campaign",
    "slug": "twitter-campaign",
    "public": true
}'

Resposta do servidor

{
    "error": 0,
    "id": 3,
    "domain": "Twitter Campaign",
    "public": true,
    "rotator": "https:\/\/domain.com\/r\/twitter-campaign",
    "list": "https:\/\/domain.com\/u\/admin\/twitter-campaign-3"
}

מחיקת קמפיין

למחוק https://urlkai.com/api/campaign/:id/delete

כדי למחוק קמפיין, עליך לשלוח בקשת מחיקה.

curl --location --request DELETE 'https://urlkai.com/api/campaign/:id/delete' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \

Resposta do servidor

{
    "error": 0,
    "message": "Campaign has been deleted successfully."
}

כנסיית קאנה

רשימת ערוצים

קיבל https://urlkai.com/api/channels?limit=2&page=1

כדי לקבל את הערוצים שלך דרך ה-API, אתה יכול להשתמש בנקודת קצה זו. באפשרותך גם לסנן נתונים (ראה טבלה לקבלת מידע נוסף).

Parâmetro Descrição
גבול (אופציונלי) תוצאת נתונים לכל עמוד
דף (אופציונלי) בקשה לדף נוכחי
curl --location --request GET 'https://urlkai.com/api/channels?limit=2&page=1' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \

Resposta do servidor

{
    "error": "0",
    "data": {
        "result": 2,
        "perpage": 2,
        "currentpage": 1,
        "nextpage": 1,
        "maxpage": 1,
        "channels": [
            {
                "id": 1,
                "name": "Channel 1",
                "description": "Description of channel 1",
                "color": "#000000",
                "starred": true
            },
            {
                "id": 2,
                "name": "Channel 2",
                "description": "Description of channel 2",
                "color": "#FF0000",
                "starred": false
            }
        ]
    }
}

פריטי ערוץ רשימה

קיבל https://urlkai.com/api/channel/:id?limit=1&page=1

כדי לקבל פריטים בערוצים נבחרים דרך ה-API, אתה יכול להשתמש בנקודת קצה זו. באפשרותך גם לסנן נתונים (ראה טבלה לקבלת מידע נוסף).

Parâmetro Descrição
גבול (אופציונלי) תוצאת נתונים לכל עמוד
דף (אופציונלי) בקשה לדף נוכחי
curl --location --request GET 'https://urlkai.com/api/channel/:id?limit=1&page=1' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \

Resposta do servidor

{
    "error": "0",
    "data": {
        "result": 2,
        "perpage": 2,
        "currentpage": 1,
        "nextpage": 1,
        "maxpage": 1,
        "items": [
            {
                "type": "links",
                "id": 1,
                "title": "My Sample Link",
                "preview": "https:\/\/google.com",
                "link": "https:\/\/urlkai.com\/google",
                "date": "2022-05-12"
            },
            {
                "type": "bio",
                "id": 1,
                "title": "My Sample Bio",
                "preview": "https:\/\/urlkai.com\/mybio",
                "link": "https:\/\/urlkai.com\/mybio",
                "date": "2022-06-01"
            }
        ]
    }
}

Criar um canal

הצבה https://urlkai.com/api/channel/add

ניתן להוסיף ערוץ באמצעות נקודת קצה זו.

Parâmetro Descrição
שם (חובה) שם הערוץ
תיאור (אופציונלי) תיאור הערוץ
צבע (אופציונלי) צבע תג ערוץ (HEX)
מסומן בכוכב (אופציונלי) סימון הערוץ בכוכב או לא (נכון או לא נכון)
curl --location --request POST 'https://urlkai.com/api/channel/add' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
--data-raw '{
    "name": "New Channel",
    "description": "my new channel",
    "color": "#000000",
    "starred": true
}'

Resposta do servidor

{
    "error": 0,
    "id": 3,
    "name": "New Channel",
    "description": "my new channel",
    "color": "#000000",
    "starred": true
}

הקצאת פריט לערוץ

הצבה https://urlkai.com/api/channel/:channelid/assign/:type/:itemid

ניתן להקצות פריט לכל ערוץ על ידי שליחת בקשה עם מזהה הערוץ, סוג הפריט (קישורים, ביו או qr) ומזהה הפריט.

Parâmetro Descrição
ערוץ: (חובה) מזהה ערוץ
:סוג (חובה) קישורים או ביוגרפיה או QR
פריט: (חובה) מזהה פריט
curl --location --request POST 'https://urlkai.com/api/channel/:channelid/assign/:type/:itemid' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \

Resposta do servidor

{
    "error": 0,
    "message": "Item successfully added to the channel."
}

תעלת אטואליזאר

שים https://urlkai.com/api/channel/:id/update

כדי לעדכן ערוץ, עליך לשלוח נתונים חוקיים ב-JSON באמצעות בקשת PUT. יש לשלוח את הנתונים כגוף הגולמי של בקשתך כפי שמוצג להלן. הדוגמה שלהלן מציגה את כל הפרמטרים שבאפשרותך לשלוח, אך אינך נדרש לשלוח את כולם (ראה טבלה למידע נוסף).

Parâmetro Descrição
שם (אופציונלי) שם הערוץ
תיאור (אופציונלי) תיאור הערוץ
צבע (אופציונלי) צבע תג ערוץ (HEX)
מסומן בכוכב (אופציונלי) סימון הערוץ בכוכב או לא (נכון או לא נכון)
curl --location --request PUT 'https://urlkai.com/api/channel/:id/update' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
--data-raw '{
    "name": "Acme Corp",
    "description": "channel for items for Acme Corp",
    "color": "#FFFFFF",
    "starred": false
}'

Resposta do servidor

{
    "error": 0,
    "message": "Channel has been updated successfully."
}

מחק ערוץ

למחוק https://urlkai.com/api/channel/:id/delete

כדי למחוק ערוץ, עליך לשלוח בקשת מחיקה. כל הפריטים לא יוקצו גם כן.

curl --location --request DELETE 'https://urlkai.com/api/channel/:id/delete' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \

Resposta do servidor

{
    "error": 0,
    "message": "Channel has been deleted successfully."
}

Códigos QR

רשימת קודי QR

קיבל https://urlkai.com/api/qr?limit=2&page=1

כדי לקבל את קודי ה-QR שלך דרך ה-API, אתה יכול להשתמש בנקודת קצה זו. באפשרותך גם לסנן נתונים (ראה טבלה לקבלת מידע נוסף).

Parâmetro Descrição
גבול (אופציונלי) תוצאת נתונים לכל עמוד
דף (אופציונלי) בקשה לדף נוכחי
curl --location --request GET 'https://urlkai.com/api/qr?limit=2&page=1' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \

Resposta do servidor

{
    "error": "0",
    "data": {
        "result": 2,
        "perpage": 2,
        "currentpage": 1,
        "nextpage": 1,
        "maxpage": 1,
        "qrs": [
            {
                "id": 2,
                "link": "https:\/\/urlkai.com\/qr\/a2d5e",
                "scans": 0,
                "name": "Google",
                "date": "2020-11-10 18:01:43"
            },
            {
                "id": 1,
                "link": "https:\/\/urlkai.com\/qr\/b9edfe",
                "scans": 5,
                "name": "Google Canada",
                "date": "2020-11-10 18:00:25"
            }
        ]
    }
}

קבל קוד QR יחיד

קיבל https://urlkai.com/api/qr/:id

כדי לקבל פרטים עבור קוד QR יחיד דרך ה-API, אתה יכול להשתמש בנקודת קצה זו.

curl --location --request GET 'https://urlkai.com/api/qr/:id' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \

Resposta do servidor

{
    "error": 0,
    "details": {
        "id": 1,
        "link": "https:\/\/urlkai.com\/qr\/b9edfe",
        "scans": 5,
        "name": "Google Canada",
        "date": "2020-11-10 18:00:25"
    },
    "data": {
        "clicks": 1,
        "uniqueClicks": 1,
        "topCountries": {
            "Unknown": "1"
        },
        "topReferrers": {
            "Direct, email and other": "1"
        },
        "topBrowsers": {
            "Chrome": "1"
        },
        "topOs": {
            "Windows 10": "1"
        },
        "socialCount": {
            "facebook": 0,
            "twitter": 0,
            "instagram": 0
        }
    }
}

צור קוד QR

הצבה https://urlkai.com/api/qr/add

כדי ליצור קוד QR, עליך לשלוח נתונים חוקיים ב-JSON באמצעות בקשת POST. יש לשלוח את הנתונים כגוף הגולמי של בקשתך כפי שמוצג להלן. הדוגמה שלהלן מציגה את כל הפרמטרים שבאפשרותך לשלוח, אך אינך נדרש לשלוח את כולם (ראה טבלה למידע נוסף).

Parâmetro Descrição
סוג טקסט (חובה) | מניית vCard | קישור | דוא"ל | טלפון | סמס | WiFi
נתונים (חובה) נתונים שיוטמעו בתוך קוד ה-QR. הנתונים יכולים להיות מחרוזת או מערך בהתאם לסוג
רקע (אופציונלי) צבע RGB למשל RGB (255,255,255)
הקידמה (אופציונלי) צבע RGB, למשל rgb(0,0,0)
לוגו (אופציונלי) נתיב ללוגו png או jpg
שם (אופציונלי) שם קוד QR
curl --location --request POST 'https://urlkai.com/api/qr/add' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
--data-raw '{
    "type": "link",
    "data": "https:\/\/google.com",
    "background": "rgb(255,255,255)",
    "foreground": "rgb(0,0,0)",
    "logo": "https:\/\/site.com\/logo.png",
    "name": "QR Code API"
}'

Resposta do servidor

{
    "error": 0,
    "id": 3,
    "link": "https:\/\/urlkai.com\/qr\/a58f79"
}

עדכן קוד QR

שים https://urlkai.com/api/qr/:id/update

כדי לעדכן קוד QR, עליך לשלוח נתונים חוקיים ב-JSON באמצעות בקשת PUT. יש לשלוח את הנתונים כגוף הגולמי של בקשתך כפי שמוצג להלן. הדוגמה שלהלן מציגה את כל הפרמטרים שבאפשרותך לשלוח, אך אינך נדרש לשלוח את כולם (ראה טבלה למידע נוסף).

Parâmetro Descrição
נתונים (חובה) נתונים שיוטמעו בתוך קוד ה-QR. הנתונים יכולים להיות מחרוזת או מערך בהתאם לסוג
רקע (אופציונלי) צבע RGB למשל RGB (255,255,255)
הקידמה (אופציונלי) צבע RGB, למשל rgb(0,0,0)
לוגו (אופציונלי) נתיב ללוגו png או jpg
curl --location --request PUT 'https://urlkai.com/api/qr/:id/update' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
--data-raw '{
    "type": "link",
    "data": "https:\/\/google.com",
    "background": "rgb(255,255,255)",
    "foreground": "rgb(0,0,0)",
    "logo": "https:\/\/site.com\/logo.png"
}'

Resposta do servidor

{
    "error": 0,
    "message": "QR has been updated successfully."
}

מחיקת קוד QR

למחוק https://urlkai.com/api/qr/:id/delete

כדי למחוק קוד QR, עליך לשלוח בקשת מחיקה.

curl --location --request DELETE 'https://urlkai.com/api/qr/:id/delete' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \

Resposta do servidor

{
    "error": 0,
    "message": "QR Code has been deleted successfully."
}

Domínios de marca

רשימת דומיינים ממותגים

קיבל https://urlkai.com/api/domains?limit=2&page=1

כדי לקבל את הדומיינים הממותגים שלך דרך ה-API, אתה יכול להשתמש בנקודת קצה זו. באפשרותך גם לסנן נתונים (ראה טבלה לקבלת מידע נוסף).

Parâmetro Descrição
גבול (אופציונלי) תוצאת נתונים לכל עמוד
דף (אופציונלי) בקשה לדף נוכחי
curl --location --request GET 'https://urlkai.com/api/domains?limit=2&page=1' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \

Resposta do servidor

{
    "error": "0",
    "data": {
        "result": 2,
        "perpage": 2,
        "currentpage": 1,
        "nextpage": 1,
        "maxpage": 1,
        "domains": [
            {
                "id": 1,
                "domain": "https:\/\/domain1.com",
                "redirectroot": "https:\/\/rootdomain.com",
                "redirect404": "https:\/\/rootdomain.com\/404"
            },
            {
                "id": 2,
                "domain": "https:\/\/domain2.com",
                "redirectroot": "https:\/\/rootdomain2.com",
                "redirect404": "https:\/\/rootdomain2.com\/404"
            }
        ]
    }
}

יצירת דומיין ממותג

הצבה https://urlkai.com/api/domain/add

ניתן להוסיף תחום באמצעות נקודת קצה זו. יש לוודא שהדומיין מופנה כראוי לשרת שלנו.

Parâmetro Descrição
תחום (חובה) דומיין ממותג כולל http או https
redirectroot (אופציונלי) הפניית בסיס כאשר מישהו מבקר בדומיין שלך
הפניה מחדש404 (אופציונלי) ניתוב מחדש מותאם אישית של 404
curl --location --request POST 'https://urlkai.com/api/domain/add' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
--data-raw '{
    "domain": "https:\/\/domain1.com",
    "redirectroot": "https:\/\/rootdomain.com",
    "redirect404": "https:\/\/rootdomain.com\/404"
}'

Resposta do servidor

{
    "error": 0,
    "id": 1
}

Atualizar domínio

שים https://urlkai.com/api/domain/:id/update

כדי לעדכן דומיין ממותג, עליך לשלוח נתונים חוקיים ב-JSON באמצעות בקשת PUT. יש לשלוח את הנתונים כגוף הגולמי של בקשתך כפי שמוצג להלן. הדוגמה שלהלן מציגה את כל הפרמטרים שבאפשרותך לשלוח, אך אינך נדרש לשלוח את כולם (ראה טבלה למידע נוסף).

Parâmetro Descrição
redirectroot (אופציונלי) הפניית בסיס כאשר מישהו מבקר בדומיין שלך
הפניה מחדש404 (אופציונלי) ניתוב מחדש מותאם אישית של 404
curl --location --request PUT 'https://urlkai.com/api/domain/:id/update' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
--data-raw '{
    "redirectroot": "https:\/\/rootdomain-new.com",
    "redirect404": "https:\/\/rootdomain-new.com\/404"
}'

Resposta do servidor

{
    "error": 0,
    "message": "Domain has been updated successfully."
}

מחיקת דומיין

למחוק https://urlkai.com/api/domain/:id/delete

כדי למחוק דומיין, צריך לשלוח בקשת מחיקה.

curl --location --request DELETE 'https://urlkai.com/api/domain/:id/delete' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \

Resposta do servidor

{
    "error": 0,
    "message": "Domain has been deleted successfully."
}

קבצים

קבצי רשימה

קיבל https://urlkai.com/api/files?limit=2&page=1

קבל את כל הקבצים שלך. אתה יכול גם לחפש לפי שם.

Parâmetro Descrição
שם (אופציונלי) חיפוש קובץ לפי שם
גבול (אופציונלי) תוצאת נתונים לכל עמוד
דף (אופציונלי) בקשה לדף נוכחי
curl --location --request GET 'https://urlkai.com/api/files?limit=2&page=1' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \

Resposta do servidor

{
    "error": 0,
    "result": 3,
    "perpage": 15,
    "currentpage": 1,
    "nextpage": null,
    "maxpage": 1,
    "list": [
        {
            "id": 1,
            "name": "My Photo",
            "downloads": 10,
            "shorturl": "https:\/\/urlkai.com\/beauR",
            "date": "2022-08-09 17:00:00"
        },
        {
            "id": 2,
            "name": "My Documents",
            "downloads": 15,
            "shorturl": "https:\/\/urlkai.com\/VlErt",
            "date": "2022-08-10 17:01:00"
        },
        {
            "id": 3,
            "name": "My Files",
            "downloads": 5,
            "shorturl": "https:\/\/urlkai.com\/MMbPY",
            "date": "2022-08-11 19:01:00"
        }
    ]
}

העלאת קובץ

הצבה https://urlkai.com/api/files/upload/:filename?name=My+File

העלה קובץ על-ידי שליחת הנתונים הבינאריים כגוף הפרסום. עליך לשלוח את שם הקובץ כולל הסיומת במקום :filename בכתובת האתר (למשל brandkit.zip). באפשרותך להגדיר אפשרויות על-ידי שליחת הפרמטרים הבאים.

Parâmetro Descrição
שם (אופציונלי) שם קובץ
מנהג (אופציונלי) כינוי מותאם אישית במקום כינוי אקראי.
תחום (אופציונלי) דומיין מותאם אישית
סיסמה (אופציונלי) הגנת סיסמה
תפוגה (אופציונלי) תפוגה עבור דוגמת ההורדה 2021-09-28
מקסימום הורדות (אופציונלי) מספר מרבי של הורדות
curl --location --request POST 'https://urlkai.com/api/files/upload/:filename?name=My+File' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
--data-raw '"BINARY DATA"'

Resposta do servidor

{
    "error": 0,
    "id": 1,
    "shorturl": "https:\/\/urlkai.com\/hnEWJ"
}

פיקסיס

רשימת פיקסלים

קיבל https://urlkai.com/api/pixels?limit=2&page=1

כדי לקבל את קודי הפיקסלים דרך ה-API, אתה יכול להשתמש בנקודת קצה זו. באפשרותך גם לסנן נתונים (ראה טבלה לקבלת מידע נוסף).

Parâmetro Descrição
גבול (אופציונלי) תוצאת נתונים לכל עמוד
דף (אופציונלי) בקשה לדף נוכחי
curl --location --request GET 'https://urlkai.com/api/pixels?limit=2&page=1' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \

Resposta do servidor

{
    "error": "0",
    "data": {
        "result": 2,
        "perpage": 2,
        "currentpage": 1,
        "nextpage": 1,
        "maxpage": 1,
        "pixels": [
            {
                "id": 1,
                "type": "gtmpixel",
                "name": "GTM Pixel",
                "tag": "GA-123456789",
                "date": "2020-11-10 18:00:00"
            },
            {
                "id": 2,
                "type": "twitterpixel",
                "name": "Twitter Pixel",
                "tag": "1234567",
                "date": "2020-11-10 18:10:00"
            }
        ]
    }
}

יצירת פיקסל

הצבה https://urlkai.com/api/pixel/add

ניתן ליצור פיקסל באמצעות נקודת קצה זו. עליך לשלוח את סוג הפיקסל ואת התיוג.

Parâmetro Descrição
סוג (נדרש) gtmpixel | גפיקסל | fbpixel | פיקסל אדוורדס | לינקדאין פיקסל | טוויטרפיקסל | adrollpixel | קורפיקסל | פינטרסט | בינג | סנאפצ'ט | רדיט | טיקטוק
שם (חובה) שם מותאם אישית לפיקסל
תג (חובה) התיוג של הפיקסל
curl --location --request POST 'https://urlkai.com/api/pixel/add' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
--data-raw '{
    "type": "gtmpixel",
    "name": "My GTM",
    "tag": "GTM-ABCDE"
}'

Resposta do servidor

{
    "error": 0,
    "id": 1
}

פיקסל Atualizar

שים https://urlkai.com/api/pixel/:id/update

כדי לעדכן פיקסל, עליך לשלוח נתונים חוקיים ב-JSON באמצעות בקשת PUT. יש לשלוח את הנתונים כגוף הגולמי של בקשתך כפי שמוצג להלן. הדוגמה שלהלן מציגה את כל הפרמטרים שבאפשרותך לשלוח, אך אינך נדרש לשלוח את כולם (ראה טבלה למידע נוסף).

Parâmetro Descrição
שם (אופציונלי) שם מותאם אישית לפיקסל
תג (חובה) התיוג של הפיקסל
curl --location --request PUT 'https://urlkai.com/api/pixel/:id/update' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \
--data-raw '{
    "name": "My GTM",
    "tag": "GTM-ABCDE"
}'

Resposta do servidor

{
    "error": 0,
    "message": "Pixel has been updated successfully."
}

מחיקת פיקסל

למחוק https://urlkai.com/api/pixel/:id/delete

כדי למחוק פיקסל, עליך לשלוח בקשת מחיקה.

curl --location --request DELETE 'https://urlkai.com/api/pixel/:id/delete' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \

Resposta do servidor

{
    "error": 0,
    "message": "Pixel has been deleted successfully."
}

Sobreposições de CTA

רשימת שכבות-על של CTA

קיבל https://urlkai.com/api/overlay?limit=2&page=1

כדי לקבל שכבות-על של CTA דרך ה-API, אתה יכול להשתמש בנקודת קצה זו. באפשרותך גם לסנן נתונים (ראה טבלה לקבלת מידע נוסף).

Parâmetro Descrição
גבול (אופציונלי) תוצאת נתונים לכל עמוד
דף (אופציונלי) בקשה לדף נוכחי
curl --location --request GET 'https://urlkai.com/api/overlay?limit=2&page=1' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \

Resposta do servidor

{
    "error": "0",
    "data": {
        "result": 2,
        "perpage": 2,
        "currentpage": 1,
        "nextpage": 1,
        "maxpage": 1,
        "cta": [
            {
                "id": 1,
                "type": "message",
                "name": "Product 1 Promo",
                "date": "2020-11-10 18:00:00"
            },
            {
                "id": 2,
                "type": "contact",
                "name": "Contact Page",
                "date": "2020-11-10 18:10:00"
            }
        ]
    }
}

Splash personalizado

רשימה התזה מותאמת אישית

קיבל https://urlkai.com/api/splash?limit=2&page=1

To get Splash Pages via the API, you can use this endpoint. You can also filter data (See table for more info).

Parâmetro Descrição
גבול (אופציונלי) תוצאת נתונים לכל עמוד
דף (אופציונלי) בקשה לדף נוכחי
curl --location --request GET 'https://urlkai.com/api/splash?limit=2&page=1' \
--header 'Authorization: Bearer YOURAPIKEY' \
--header 'Content-Type: application/json' \

Resposta do servidor

{
    "error": "0",
    "data": {
        "result": 2,
        "perpage": 2,
        "currentpage": 1,
        "nextpage": 1,
        "maxpage": 1,
        "splash": [
            {
                "id": 1,
                "name": "Product 1 Promo",
                "date": "2020-11-10 18:00:00"
            },
            {
                "id": 2,
                "name": "Product 2 Promo",
                "date": "2020-11-10 18:10:00"
            }
        ]
    }
}