facebook.proto 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183
  1. syntax = "proto2";
  2. message Credential {
  3. optional string facebook_uid = 0x1;
  4. optional string access_token = 0x2;
  5. }
  6. message EnableRequest {
  7. optional Credential credential = 0x1;
  8. }
  9. message EnableReply {
  10. optional Credential credential = 0x1;
  11. }
  12. message DisableRequest {
  13. optional Credential credential = 0x1;
  14. }
  15. message RevokeRequest {
  16. optional Credential credential = 0x1;
  17. }
  18. message InspectCredentialRequest {
  19. optional Credential credential = 0x1;
  20. }
  21. message InspectCredentialReply {
  22. optional Credential alternative_credential = 0x1;
  23. optional bool app_user = 0x2;
  24. optional bool permanent_error = 0x3;
  25. optional bool transient_error = 0x4;
  26. }
  27. message UserState {
  28. optional Credential credential = 0x1;
  29. }
  30. message UpdateUserStateRequest {
  31. optional Credential credential = 0x1;
  32. }
  33. message OpenGraphError {
  34. repeated string permanent = 0x1;
  35. repeated string invalid_token = 0x2;
  36. repeated string retries = 0x3;
  37. }
  38. message OpenGraphScrobble {
  39. optional int32 create_delay = 0x1;
  40. }
  41. message OpenGraphConfig {
  42. optional OpenGraphError error = 0x1;
  43. optional OpenGraphScrobble scrobble = 0x2;
  44. }
  45. message AuthConfig {
  46. optional string url = 0x1;
  47. repeated string permissions = 0x2;
  48. repeated string blacklist = 0x3;
  49. repeated string whitelist = 0x4;
  50. repeated string cancel = 0x5;
  51. }
  52. message ConfigReply {
  53. optional string domain = 0x1;
  54. optional string app_id = 0x2;
  55. optional string app_namespace = 0x3;
  56. optional AuthConfig auth = 0x4;
  57. optional OpenGraphConfig og = 0x5;
  58. }
  59. message UserFields {
  60. optional bool app_user = 0x1;
  61. optional bool display_name = 0x2;
  62. optional bool first_name = 0x3;
  63. optional bool middle_name = 0x4;
  64. optional bool last_name = 0x5;
  65. optional bool picture_large = 0x6;
  66. optional bool picture_square = 0x7;
  67. optional bool gender = 0x8;
  68. optional bool email = 0x9;
  69. }
  70. message UserOptions {
  71. optional bool cache_is_king = 0x1;
  72. }
  73. message UserRequest {
  74. optional UserOptions options = 0x1;
  75. optional UserFields fields = 0x2;
  76. }
  77. message User {
  78. optional string spotify_username = 0x1;
  79. optional string facebook_uid = 0x2;
  80. optional bool app_user = 0x3;
  81. optional string display_name = 0x4;
  82. optional string first_name = 0x5;
  83. optional string middle_name = 0x6;
  84. optional string last_name = 0x7;
  85. optional string picture_large = 0x8;
  86. optional string picture_square = 0x9;
  87. optional string gender = 0xa;
  88. optional string email = 0xb;
  89. }
  90. message FriendsFields {
  91. optional bool app_user = 0x1;
  92. optional bool display_name = 0x2;
  93. optional bool picture_large = 0x6;
  94. }
  95. message FriendsOptions {
  96. optional int32 limit = 0x1;
  97. optional int32 offset = 0x2;
  98. optional bool cache_is_king = 0x3;
  99. optional bool app_friends = 0x4;
  100. optional bool non_app_friends = 0x5;
  101. }
  102. message FriendsRequest {
  103. optional FriendsOptions options = 0x1;
  104. optional FriendsFields fields = 0x2;
  105. }
  106. message FriendsReply {
  107. repeated User friends = 0x1;
  108. optional bool more = 0x2;
  109. }
  110. message ShareRequest {
  111. optional Credential credential = 0x1;
  112. optional string uri = 0x2;
  113. optional string message_text = 0x3;
  114. }
  115. message ShareReply {
  116. optional string post_id = 0x1;
  117. }
  118. message InboxRequest {
  119. optional Credential credential = 0x1;
  120. repeated string facebook_uids = 0x3;
  121. optional string message_text = 0x4;
  122. optional string message_link = 0x5;
  123. }
  124. message InboxReply {
  125. optional string message_id = 0x1;
  126. optional string thread_id = 0x2;
  127. }
  128. message PermissionsOptions {
  129. optional bool cache_is_king = 0x1;
  130. }
  131. message PermissionsRequest {
  132. optional Credential credential = 0x1;
  133. optional PermissionsOptions options = 0x2;
  134. }
  135. message PermissionsReply {
  136. repeated string permissions = 0x1;
  137. }
  138. message GrantPermissionsRequest {
  139. optional Credential credential = 0x1;
  140. repeated string permissions = 0x2;
  141. }
  142. message GrantPermissionsReply {
  143. repeated string granted = 0x1;
  144. repeated string failed = 0x2;
  145. }
  146. message TransferRequest {
  147. optional Credential credential = 0x1;
  148. optional string source_username = 0x2;
  149. optional string target_username = 0x3;
  150. }