Jump to content

How to create a task to scan a single library?


Recommended Posts

randallspicher
Posted

I hope someone can help me on this.    I've got a bunch of libraries added to Emby (TV Shows, Movies, Anime, etc) most of which rarely change.  I've also got one Library that *does* change frequently, and I'd like to set that up to scan more frequently then the other, non-changing libraries.

I cannot find anything about scanning frequency or scheduling on the library settings dialogs.  And on the tasks, I only see the "scan every library on your system" task, which I do not want because scanning every library is extremely time consuming, and not needed.  And cannot see any way of creating a new task.

So, how do I set up a task that only scans one of my libraries?

And no, the "detect filesystem changes" does not work in this case (running on linux, under docker, and the library in question is on a virtual remote file system, emby cannot detect filesystem changes on it).

 

GrimReaper
Posted (edited)
29 minutes ago, randallspicher said:

So, how do I set up a task that only scans one of my libraries?

That is currently not possible. You can only manually scan particular library via three-dot menu on library thumb (either on Home Screen or Settings>Library tab)>Scan Library Files.

Edited by GrimReaper
Happy2Play
Posted (edited)

There isn't one beside manually triggering one on the library.

You have to use th api or debug the log on a library scan and create your own script and run at your own interval via your platform.

image.png

You will have to use the curl command you see in the api and will have to generate a API Key via app settings-API keys to replace the one in the curl command in your own script as the one generated in the api expires.

 

There several other topics out there.

 

Edited by Happy2Play
  • Like 1
  • 1 year later...
lightsout
Posted
On 2/5/2023 at 6:32 PM, Happy2Play said:

There isn't one beside manually triggering one on the library.

You have to use th api or debug the log on a library scan and create your own script and run at your own interval via your platform.

image.png

You will have to use the curl command you see in the api and will have to generate a API Key via app settings-API keys to replace the one in the curl command in your own script as the one generated in the api expires.

 

There several other topics out there.

 

What software is the screenshot of?

Happy2Play
Posted
1 minute ago, lightsout said:

What software is the screenshot of?

That is the Emby API.

Link at bottom of dashboard.

If your connection is not localhost or https you will need to adjust browser flags to work around CORS.

 

lightsout
Posted
3 hours ago, Happy2Play said:

That is the Emby API.

Link at bottom of dashboard.

If your connection is not localhost or https you will need to adjust browser flags to work around CORS.

 

Thanks, I think this is beyond my need and ability to mess with.

Happy2Play
Posted
2 minutes ago, lightsout said:

Thanks, I think this is beyond my need and ability to mess with.

What exactly are your trying to do per your topic?

lightsout
Posted
5 hours ago, Happy2Play said:

What exactly are your trying to do per your topic?

Find an easier way to trigger a library scan than going into the dashboard and finding the library.

Happy2Play
Posted
7 hours ago, lightsout said:

Thanks, I think this is beyond my need and ability to mess with.

 

1 hour ago, lightsout said:

Find an easier way to trigger a library scan than going into the dashboard and finding the library.

Information is already shown in the links as all you need is your api key and/or specific library parentid depending on a single or all libraries.

Create a bat/cmd file and put it wherever you like.

Specific library

C:\Windows\System32\curl -X POST "http://localhost:8096/emby/Items/PARENTID/Refresh?Recursive=true&MetadataRefreshMode=Default&ImageRefreshMode=Default&ReplaceAllMetadata=false&ReplaceAllImages=false&api_key={API KEY}" -d ""

All libraries

C:\Windows\System32\curl -X POST "http://localhost:8096/emby/Library/Refresh?Recursive=true&MetadataRefreshMode=Default&ImageRefreshMode=Default&ReplaceAllMetadata=false&ReplaceAllImages=false&api_key={API KEY}" -d ""

 

lightsout
Posted
12 hours ago, Happy2Play said:

 

Information is already shown in the links as all you need is your api key and/or specific library parentid depending on a single or all libraries.

Create a bat/cmd file and put it wherever you like.

Specific library

C:\Windows\System32\curl -X POST "http://localhost:8096/emby/Items/PARENTID/Refresh?Recursive=true&MetadataRefreshMode=Default&ImageRefreshMode=Default&ReplaceAllMetadata=false&ReplaceAllImages=false&api_key={API KEY}" -d ""

All libraries

C:\Windows\System32\curl -X POST "http://localhost:8096/emby/Library/Refresh?Recursive=true&MetadataRefreshMode=Default&ImageRefreshMode=Default&ReplaceAllMetadata=false&ReplaceAllImages=false&api_key={API KEY}" -d ""

 

Thank you

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...