onny 0 Posted February 26, 2019 Share Posted February 26, 2019 Hey, is it possible to query an item by searching for the file path or file name? Thank you and best regards, Jonas Link to post Share on other sites
Luke 25799 Posted February 26, 2019 Share Posted February 26, 2019 Hi, no, but it's a good idea to add this. We can add Path for the next release, since that's something we currently keep in the database. Thanks. 1 Link to post Share on other sites
henriquefer 3 Posted February 6, 2020 Share Posted February 6, 2020 Hi, no, but it's a good idea to add this. We can add Path for the next release, since that's something we currently keep in the database. Thanks. Any developments regarding this? Link to post Share on other sites
Luke 25799 Posted February 7, 2020 Share Posted February 7, 2020 Hi, looks like a Path param is already present. Granted I think this might difficult on the query string, but give it a shot. Thanks. Link to post Share on other sites
TheShanMan 29 Posted April 4, 2020 Share Posted April 4, 2020 I've been trying to get this Path parameter to work either with a partial path or a full path including the filename but can't get it to work (returns 0 items). Here's a sample of what I'm trying: http://myserver:8096/Items?Recursive=true&Fields=Path&Path=%5C%5Cmyserver%5Cmyshare%5CVideo%5Cmyshow.avi Is this parameter functional? Do I need to specify another parameter to get it to work? Ultimately I'd like to specify a partial path in order to get all items inside a directory (recursively). Link to post Share on other sites
Luke 25799 Posted April 4, 2020 Share Posted April 4, 2020 It needs to be the full path and it needs to match the path that emby server has for it, so partials will not work. Link to post Share on other sites
PenkethBoy 1938 Posted April 4, 2020 Share Posted April 4, 2020 (edited) You can do this as a two stage process add your path to the path search i used "e:\serverfolders\multimedia\movies" dont add a trailing slash as it will then fail or something longer like "e:\serverfolders\multimedia\movies\Alien" the above path is the root of my movies library - just an example the returned json has the ID of my Movies directory take this ID and clear out the path you put in earlier then put the id number in parentID , make recursive to true, put includeitemtype to movie(or whatever you need) and add "path" to the fields box you will get a list of all movies with the parent ID and the full path to each file etc not elegant - but works from swagger "http://192.168.1.80:8096/emby/Items?Recursive=true&ParentId=6&IncludeItemTypes=movie&api_key=0c66fd28d42d4e6a82aa885500e29348" Edited April 4, 2020 by PenkethBoy Link to post Share on other sites
TheShanMan 29 Posted April 5, 2020 Share Posted April 5, 2020 It needs to be the full path and it needs to match the path that emby server has for it, so partials will not work. My example is a full path, which I tried both URI encoded and as plain text. Didn't work either way. You can do this as a two stage process add your path to the path search i used "e:\serverfolders\multimedia\movies" dont add a trailing slash as it will then fail or something longer like "e:\serverfolders\multimedia\movies\Alien" What is the "path search"? take this ID and clear out the path you put in earlier then put the id number in parentID , make recursive to true, put includeitemtype to movie(or whatever you need) and add "path" to the fields box Yeah, if I grab an ID from a folder URL when I browse to it in my browser, I can use it as you suggest. Thanks for that tip. Link to post Share on other sites
PenkethBoy 1938 Posted April 5, 2020 Share Posted April 5, 2020 path search is the option to search by "path" in swagger if used alone it returns very basic info on the last folder in the path provided - which includes the ID Link to post Share on other sites
TheShanMan 29 Posted April 5, 2020 Share Posted April 5, 2020 I have been looking at swagger but you and I must be doing it differently, which is why I asked. I'm doing "/Items?Path=" and it doesn't matter whether I use the local path, UNC path, or either of those paths URI encoded. No matter what I try I get "Unable to find the specified file." Link to post Share on other sites
PenkethBoy 1938 Posted April 5, 2020 Share Posted April 5, 2020 yes same endpoint and it does work gives Dont understand why you are going via a path get the library id, then get the media , compare path you are looking for with individual item path or part of it Link to post Share on other sites
TheShanMan 29 Posted April 5, 2020 Share Posted April 5, 2020 Hmm... looks the same to me. Wonder why it fails for me. Link to post Share on other sites
PenkethBoy 1938 Posted April 5, 2020 Share Posted April 5, 2020 without any detail impossible to say Link to post Share on other sites
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now