# API returning user ID of -1 when uploading avatar

**URL:** <https://meta.discourse.org/t/api-returning-user-id-of-1-when-uploading-avatar/71784>\
**Category:** Development\
**Created:** [2017 年 10 月 10 日午後 8:45 UTC](https://meta.discourse.org/t/api-returning-user-id-of-1-when-uploading-avatar/71784 "2017-10-10T20:45:16Z")\
**Posts on this page:** 1\
**Showing post:** 5

<div class="post-metadata">

**Author:** ![MakaryGo](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/makarygo/32/187426_2.png) [@MakaryGo](https://meta.discourse.org/u/MakaryGo)\
**Post date:** [2017 年 10 月 11 日午前 9:36 UTC](https://meta.discourse.org/t/api-returning-user-id-of-1-when-uploading-avatar/71784/5 "2017-10-11T09:36:45Z")

</div>

Because you have to specify `user_id` that is connecting with API, the one that the API Key is issued for, I guess?

---

_[View the full topic](https://meta.discourse.org/t/api-returning-user-id-of-1-when-uploading-avatar/71784)._
