Skip to content
Nicolas Schmitt edited this page Aug 21, 2016 · 3 revisions

Socket documentation

bot_initialized

Bot is ready. Send user info and initial position.

{ username: "username", player: { level: 1, experience: 600, prev_level_xp: 0, next_level_xp: 1000 }, storage: { max_pokemon_storage: 250, max_item_storage: 350 }, coordinates: [48.856297, 2.297987] }

pokemon_settings

Send item_templates related to pokemon settings. Aray of object like that:

[{"animation_time":[1.666700005531311,0.666700005531311,1.666700005531311,1.833299994468689,0,2.1666998863220215,1.399999976158142,1.4666670560836792],"evolution_pips":1,"stats":{"base_stamina":90,"base_defense":126,"base_attack":126},"height_std_dev":0.08749999850988388,"evolution_ids":[2],"model_scale":1.090000033378601,"quick_moves":[214,221],"type_2":4,"family_id":1,"camera":{"disk_radius_m":0.5723000168800354,"shoulder_mode_scale":0.5,"cylinder_height_m":0.7630000114440918,"cylinder_radius_m":0.3815000057220459},"pokedex_height_m":0.699999988079071,"cinematic_moves":[90,59,118],"candy_to_evolve":25,"weight_std_dev":0.862500011920929,"pokedex_weight_kg":6.900000095367432,"type":12,"pokemon_id":1,"encounter":{"movement_timer_s":10,"collision_head_radius_m":0.27250000834465027,"attack_timer_s":29,"collision_height_m":0.6539999842643738,"collision_radius_m":0.3815000057220459,"movement_type":1,"base_capture_rate":0.1599999964237213,"base_flee_rate":0.10000000149011612,"jump_time_s":1.149999976158142}}, ...]

player_stats

{ player: { level: 1, experience: 600, prev_level_xp: 0, next_level_xp: 1000 } }

position

{ coordinates: [48.856297, 2.297987] }

pokestops

List available pokestops

{ pokestops: [{"lure_encounter_id":"231495783","fort_type":"1","last_modified_timestamp_ms":"1471268800152","lure_expires_timestamp_ms":"1471269700119","fort_id":"14ca7e4d54974ffbbf2c262a6e2e3f48.16","enabled":"True","longitude":2.299981,"latitude":48.85415,"fort_name":"Unknown","lure_pokemon_id":"127","active_fort_modifier":"9QM=","cooldown_timestamp_ms":null}, ...]}

pokestop_visited

When a pokestop has been spinned

{ pokestop: { fort_id: "1234", latitude: 42, longitude: 2.5, cooldown_timestamp_ms: "1471268800152", lure_expires_timestamp_ms: null }}

pokemon_caught

{ pokemon: { pokemon_id: 15, combat_power: 1000, potential: 0.8, combat_power_multiplier: 0.094, additional_cp_multiplier: 0 }

pokemon_evolved

{ pokemon { pokemon_id: (pokemon id before evolution) }, evolution: (pokemon id of evolved pokemon) }