JSON-RPC (JSON Remote Procedure Call) interface protocol in development for XBMC - Printable Version +- Kodi Community Forum (https://forum.kodi.tv) +-- Forum: Development (https://forum.kodi.tv/forumdisplay.php?fid=32) +--- Forum: Kodi Application (https://forum.kodi.tv/forumdisplay.php?fid=93) +---- Forum: JSON-RPC (https://forum.kodi.tv/forumdisplay.php?fid=174) +---- Thread: JSON-RPC (JSON Remote Procedure Call) interface protocol in development for XBMC (/showthread.php?tid=68263) Pages:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
|
RE: JSON-RPC (JSON Remote Procedure Call) interface protocol in development for XBMC - doozer - 2012-11-19 I'm having a bit of brain failure... can anyone see what i'm doing wrong here? Frodo nightly build from about 3 days ago. Code: {"jsonrpc": "2.0", "method": "AudioLibrary.GetArtistDetails", "params": {"artistid": 3,"properties": ["fanart", "description"]}, "id": "AudioLibrary.GetArtistDetails"} Returns: Code: {"error":{"code":-32602,"message":"Invalid params."},"id":"AudioLibrary.GetArtistDetails","jsonrpc":"2.0"} Thanks, Matt. RE: JSON-RPC (JSON Remote Procedure Call) interface protocol in development for XBMC - Montellese - 2012-11-19 It means that there's no artist with an ID 3. RE: JSON-RPC (JSON Remote Procedure Call) interface protocol in development for XBMC - Montellese - 2012-11-19 (2012-11-19, 01:22)VeeV Wrote: Ok, I think the same is happening with channel, channeltype, hidden, locked, endtime, channelnumber, tag, starttime. Might be worth double checking it. Fixed in https://github.com/xbmc/xbmc/commit/d938545e61b86f334d66f87dcfb2920a95a63d93. RE: JSON-RPC (JSON Remote Procedure Call) interface protocol in development for XBMC - VeeV - 2012-11-19 (2012-11-19, 09:49)Montellese Wrote:(2012-11-19, 01:22)VeeV Wrote: Ok, I think the same is happening with channel, channeltype, hidden, locked, endtime, channelnumber, tag, starttime. Might be worth double checking it. We are missing "dateadded" too I think. RE: JSON-RPC (JSON Remote Procedure Call) interface protocol in development for XBMC - doozer - 2012-11-20 (2012-11-19, 08:46)doozer Wrote: I'm having a bit of brain failure... can anyone see what i'm doing wrong here? Hi Montellese, Ok, so if artist 3 doesn't exist, I need to take a step back and show how i got the id: Code: {"jsonrpc": "2.0", "method": "Player.GetItem", "params": {"playerid": 0, "properties": ["title","artist","artistid","year","rating","albumartist","track","duration","genre","album","thumbnail","fanart"]}, "id": "Player.GetItem"} As you can see, I'm requesting the artistid as one of the params. The response i get is: Code: {"id":"Player.GetItem","jsonrpc":"2.0","result":{"item":{"album":"Greatest Hits","albumartist":[],"artist":["Eurythmics"],"duration":227,"fanart":"","genre":["Misc"],"id":3,"label":"Who's That Girl?","rating":0,"thumbnail":"image://DefaultAlbumCover.png/","title":"Who's That Girl?","track":3,"type":"song","year":1991}}} If the "id":3 isn't the artistid, what is it, and how should I go about getting the currently playing artistid? Thanks, Matt. RE: JSON-RPC (JSON Remote Procedure Call) interface protocol in development for XBMC - N3MIS15 - 2012-11-20 In that example 3 is the song id. See "type". To get the fanart and description you could use AudioLibrary.GetArtists and filter by artist RE: JSON-RPC (JSON Remote Procedure Call) interface protocol in development for XBMC - doozer - 2012-11-20 (2012-11-20, 07:09)N3MIS15 Wrote: In that example 3 is the song id. See "type". To get the fanart and description you could use AudioLibrary.GetArtists and filter by artist Ok, but why is the artistid ignored in the request? RE: JSON-RPC (JSON Remote Procedure Call) interface protocol in development for XBMC - N3MIS15 - 2012-11-20 (2012-11-20, 07:52)doozer Wrote:(2012-11-20, 07:09)N3MIS15 Wrote: In that example 3 is the song id. See "type". To get the fanart and description you could use AudioLibrary.GetArtists and filter by artist Long story, but in essence because its possible to have more than 1 artist per song/album artistid is no longer returned. Re: RE: JSON-RPC (JSON Remote Procedure Call) interface protocol in development for XBMC - Martijn - 2012-11-20 (2012-11-20, 08:14)N3MIS15 Wrote:(2012-11-20, 07:52)doozer Wrote:(2012-11-20, 07:09)N3MIS15 Wrote: In that example 3 is the song id. See "type". To get the fanart and description you could use AudioLibrary.GetArtists and filter by artist We are discussing this and it may return. RE: JSON-RPC (JSON Remote Procedure Call) interface protocol in development for XBMC - Samtronic - 2012-11-20 Hi ! I switch to frodo yesterday and I try this command {"jsonrpc": "2.0", "method": "audiolibrary.GetAlbums", "params": {"artistid": 3,"properties": ["thumbnail", "title", "fanart", "artist"] }, "id": 1} and I receiceve code = -32602 data: { ..message = Too many parameters ..method = AudioLibrary.GetAlbums ..stack: { ....name = Item.Fields.Base ....property: { ......type = string ....} ....type = array ..} } message = Invalid params. Thanks RE: JSON-RPC (JSON Remote Procedure Call) interface protocol in development for XBMC - Montellese - 2012-11-20 Yeah all those filtering parameters like "artistid" and "genreid" have been moved into a "filter" parameter so you need to do Code: {"jsonrpc": "2.0", "method": "audiolibrary.GetAlbums", "params": {"properties": ["thumbnail", "title", "fanart", "artist"], "filter": { "artistid": 3 } }, "id": 1} RE: JSON-RPC (JSON Remote Procedure Call) interface protocol in development for XBMC - Samtronic - 2012-11-20 Thanks for your help RE: JSON-RPC (JSON Remote Procedure Call) interface protocol in development for XBMC - Tolriq - 2012-11-20 Got a report today of a problem using JSON Files.GetDirectory with sources that targets upnp. I quote here : (2012-11-20, 20:15)ears Wrote: OK This is repeatable so I did it again with debug logging enabled. (2012-11-20, 22:06)ears Wrote: Yes. Seems like Files.GetDirectory does not init something on Xbmc side. RE: JSON-RPC (JSON Remote Procedure Call) interface protocol in development for XBMC - Tolriq - 2012-11-22 Any idea about this ? Should I open a trac ticket but on witch category ? RE: JSON-RPC (JSON Remote Procedure Call) interface protocol in development for XBMC - Montellese - 2012-11-22 I'm trying to get my hands on alcoheca which has refactored the whole upnp code. Files.GetDirectory() simply calls CDirectory::GetDirectory() in XBMC which will pick whatever filesystem implementation is needed (in this case CPUPnPDirectory) and calls its GetDirectory() implementation. |