Latest stories

sync

  • Inputs
{
    "lat": "float numeric: latitude, has dependency to long: optional",
    "long": "float numeric: longitude, has dependency to lat: optional",
    "new": "integer: only gets 1 or 2: optional. If new parameter is not present, output will include first and last messages for all user's chats provided that they had been received after last call to get_message_acknowledge and sync_acknowledge. If new parameter equals to 2, in addition to no new result, first and last message for chats which did not appear in the primary result, will be considered only after last call to sync_acknowledge. If new equals to 1, in addition to no new result, last message for chats which did not appear in the primary result, will be included in result with no further condition",
    "not_active": "integer: only gets 1: User becomes invisible: optional",
    "update_call": "integer: only gets 1:Output will include incoming calls (if any): optional",
    "update_chats": "list of string: Output will include only first and last messages of these specific chats, which had been received after last call to get_message_acknowledge, sync_acknowledge: optional",
    "update_last_seen": "integer: only gets 1: If not_active is not present user's last_active_time gets updated : optional",
    "update_user": "integer: only gets 1: User's last_edit_time gets updated : optional",
    "version": "string: length between 5 and 12 characters: version :optional"
}

  • Errors
{
    "must_login": "user must be login",
    "new": [
        {
            "min value is 1": "minimum valid value is 1"
        },
        {
            "max value is 2": "maximum valid value is 2"
        }
    ],
    "not_active": [
        {
            "min value is 1": "minimum valid value is 1"
        },
        {
            "max value is 1": "maximum valid value is 1"
        }
    ],
    "update_call": [
        {
            "min value is 1": "minimum valid value is 1"
        },
        {
            "max value is 1": "maximum valid value is 1"
        }
    ],
    "update_last_seen": [
        {
            "min value is 1": "minimum valid value is 1"
        },
        {
            "max value is 1": "maximum valid value is 1"
        }
    ],
    "update_user": [
        {
            "min value is 1": "minimum valid value is 1"
        },
        {
            "max value is 1": "maximum valid value is 1"
        }
    ],
    "version": [
        {
            "min length is 5": "minimum length of version is 5"
        },
        {
            "max length is 12": "maximum length of version is 12"
        }
    ]
}

  • Extra Description
Returns a full information on the active session from messages to calls and maps

  • Sample
  • Url:
https://api.pantel.me/a/sync?new=1&lat=50.8712&long=14.877
  • Output:
                                {
    "last_edit_time": [
        1547454090.2415278,
        1547468295.1656282,
        1547461925.4819887,
        1547559285.6827128,
        0,
        1545743421.326059
    ],
    "on_going_calls": null,
    "show_comment": 0,
    "static_map_server_address": "http://URL/get_static_map",
    "status": "success",
    "time": 1547619108.543094,
    "update_message_id": 1545657010421104,
    "updates": {
        "01061387bfbfa7f66fbe290deae2e7f3b479": [
            {
                "body": "Xcihowxgx - text message",
                "bot_callback": false,
                "counter": 0,
                "date": 1545657010.4225993,
                "edit_date": null,
                "forwarded": null,
                "liked": 0,
                "likes": 0,
                "local_id": null,
                "media": null,
                "media_type": 0,
                "message_id": 1545657010421104,
                "og_data": null,
                "parent_message": null,
                "reply_markup": null,
                "seen": 5,
                "sender": 1000921,
                "sender_contact_name": null,
                "sender_first_name": "Xgxikswzx",
                "sender_image_path": null,
                "sender_image_server_id": null,
                "sender_last_name": "Xzgfjuhix",
                "type": 1
            },
            {
                "body": "Xcihowxgx - text message",
                "bot_callback": false,
                "counter": 0,
                "date": 1545657011.2104027,
                "edit_date": null,
                "forwarded": null,
                "liked": 0,
                "likes": 0,
                "local_id": null,
                "media": null,
                "media_type": 0,
                "message_id": 1545657011208359,
                "og_data": null,
                "parent_message": null,
                "reply_markup": null,
                "seen": 5,
                "sender": 1000921,
                "sender_contact_name": null,
                "sender_first_name": "Xgxikswzx",
                "sender_image_path": null,
                "sender_image_server_id": null,
                "sender_last_name": "Xzgfjuhix",
                "type": 1
            },
            {
                "chat_image_path": null,
                "chat_image_server_id": null,
                "chat_name": "GoodBlog",
                "chat_type": 2,
                "is_mute": false,
                "last_seen": 1545743421.3237383,
                "other_party_id": null,
                "system_chat": 0,
                "unread_messages": 0,
                "wall_id": -1000378,
                "wall_name": "GoodBlog"
            }
        ]
    }
}