Tutorial:How to Add Files for Dummies!/The Prolix Addendum: Difference between revisions

From AniDB
Jump to navigation Jump to search
(Created page with "[//anidb.net Anime DataBase (AniDB)] is a website that provides information about Anime. It keeps track of [//anidb.net/perl-bin/animedb.pl?show=anime&aid=109 show informatio...")
 
(fixed links)
Line 65: Line 65:
In the last box of characters labeled <code>a-z, A-Z, 0-9</code>, highlight 20-30 characters as shown below.
In the last box of characters labeled <code>a-z, A-Z, 0-9</code>, highlight 20-30 characters as shown below.


[[File:grc_pp_20charas_highlight.guide.png|border|i.imgur.com/Z3D68ca.guide.png|]]
[[File:grc_pp_20charas_highlight.guide.png|border|i.imgur.com/Z3D68ca.png|]]


Then copy the selected characters to the clipboard.
Then copy the selected characters to the clipboard.
Line 72: Line 72:
* <code>Ctrl + c</code>
* <code>Ctrl + c</code>


[[File:grc_pp_20characters_copy.guide.png|border|i.imgur.com/3qlV9iu.guide.png]]
[[File:grc_pp_20characters_copy.guide.png|border|i.imgur.com/3qlV9iu.png]]


Change tabs back to AniDB's page.
Change tabs back to AniDB's page.


In the empty field under the <code>UDP API Key</code>, right-click and select <code>Paste</code>. Alternatively: <code>Ctrl + v</code>.<br />
In the empty field under the <code>UDP API Key</code>, right-click and select <code>Paste</code>. Alternatively: <code>Ctrl + v</code>.<br />
[[File:anidb_account_udpAPIKey_paste.guide.png|i.imgur.com/3V61Mo2.guide.png]]
[[File:anidb_account_udpAPIKey_paste.guide.png|i.imgur.com/3V61Mo2.png]]


[[File:anidb_account_udpAPIKey_inserted.guide.png|i.imgur.com/q5yZPHa.guide.png]]
[[File:anidb_account_udpAPIKey_inserted.guide.png|i.imgur.com/q5yZPHa.png]]


Click on the <code>Apply</code> button at the bottom. It should be right above <code>Back</code>.<br />
Click on the <code>Apply</code> button at the bottom. It should be right above <code>Back</code>.<br />
[[File:anidb_account_udpAPIKey_apply.guide.png|i.imgur.com/6761Qg3.guide.png]]<br />
[[File:anidb_account_udpAPIKey_apply.guide.png|i.imgur.com/6761Qg3.png]]<br />
The <code>UDP API Key</code> field should turn into asterisks (*) to show that it has saved it properly.<br />
The <code>UDP API Key</code> field should turn into asterisks (*) to show that it has saved it properly.<br />
[[File:anidb_account_udpAPIKey_asterisks.guide.png|i.imgur.com/l9OzPgu.guide.png]]<br />
[[File:anidb_account_udpAPIKey_asterisks.guide.png|i.imgur.com/l9OzPgu.png]]<br />
The API key should also be saved for use with Avdump2 later on, so lets save it to notepad.
The API key should also be saved for use with Avdump2 later on, so lets save it to notepad.


<code>Windows key</code> or Click on the start menu and type in <code>notepad</code>.
<code>Windows key</code> or Click on the start menu and type in <code>notepad</code>.


[[File:windowskey_notepad.guide.png|i.imgur.com/SVi1A65.guide.png|]]
[[File:windowskey_notepad.guide.png|i.imgur.com/SVi1A65.png|]]


[[File:notepad_apiKey_paste.guide.png|i.imgur.com/juAtU1M.guide.png]]
[[File:notepad_apiKey_paste.guide.png|i.imgur.com/juAtU1M.png]]


Save the file as something descriptive or as <code>anidb_apiKey.txt</code> in your user profile folder (<code>C:\Users\User</code>) or desktop (<code>C:\Users\User\Desktop</code>).
Save the file as something descriptive or as <code>anidb_apiKey.txt</code> in your user profile folder (<code>C:\Users\User</code>) or desktop (<code>C:\Users\User\Desktop</code>).
Line 100: Line 100:
Changes to the API key are updated immediately server-side but old entries are cached for an unspecified amount of time, usually less than 30 minutes. Attempting to use the new key before the old key has been removed from the cache will produce this error in the <code>Avdump2cl.exe</code>:
Changes to the API key are updated immediately server-side but old entries are cached for an unspecified amount of time, usually less than 30 minutes. Attempting to use the new key before the old key has been removed from the cache will produce this error in the <code>Avdump2cl.exe</code>:


[[File:Avdump2cl_apiKey_timeout.guide.png|i.imgur.com/SAZIZt8.guide.png]]
[[File:Avdump2cl_apiKey_timeout.guide.png|i.imgur.com/SAZIZt8.png]]


The Avdump2 GUI will simply not respond when authentication fails. More on this later.
The Avdump2 GUI will simply not respond when authentication fails. More on this later.
Line 157: Line 157:
At the top right next to <code>Search</code> change the search type from <code>all</code> to <code>group</code>.
At the top right next to <code>Search</code> change the search type from <code>all</code> to <code>group</code>.


[[File:anidb_search_group1.guide.png|i.imgur.com/4U31JYW.guide.png]]
[[File:anidb_search_group1.guide.png|i.imgur.com/4U31JYW.png]]


Enter the group name found in the filename and click on <code>Search</code>. In the example below, <code>Doki</code> is used as an example of a group (highlighted for emphasis).
Enter the group name found in the filename and click on <code>Search</code>. In the example below, <code>Doki</code> is used as an example of a group (highlighted for emphasis).
Line 222: Line 222:
* <code>Windows key</code> - Type <code>cmd.exe</code> and press <code>Enter</code>.
* <code>Windows key</code> - Type <code>cmd.exe</code> and press <code>Enter</code>.


[[File:windowskey_cmd.guide.png|i.imgur.com/zV1Hyk3.guide.png]]
[[File:windowskey_cmd.guide.png|i.imgur.com/zV1Hyk3.png]]


[[File:cmd_empty.guide.png|i.imgur.com/A3nbNdc.guide.png]]
[[File:cmd_empty.guide.png|i.imgur.com/A3nbNdc.png]]


Let's change the current path to <code>C:\Users\User\Downloads\avdump-gui-2.3.2-portable\appdata\avdump-gui-2.3.2.win32</code> using <code>cd</code> or <code>pushd</code>.
Let's change the current path to <code>C:\Users\User\Downloads\avdump-gui-2.3.2-portable\appdata\avdump-gui-2.3.2.win32</code> using <code>cd</code> or <code>pushd</code>.
Line 234: Line 234:
Open an explorer window to: <code>C:\Users\User\Downloads\avdump-gui-2.3.2-portable\appdata\avdump-gui-2.3.2.win32</code> and drag and drop the folder icon on the top left of the address bar to the command prompt window.
Open an explorer window to: <code>C:\Users\User\Downloads\avdump-gui-2.3.2-portable\appdata\avdump-gui-2.3.2.win32</code> and drag and drop the folder icon on the top left of the address bar to the command prompt window.


[[File:cmd_drag_folder.guide.png|i.imgur.com/lZGLh8B.guide.png]]
[[File:cmd_drag_folder.guide.png|i.imgur.com/lZGLh8B.png]]


This will populate the command prompt window with the path to the folder automatically, as shown below. This technique can also be used for individual files.
This will populate the command prompt window with the path to the folder automatically, as shown below. This technique can also be used for individual files.


[[File:cmd_drag_folder2.guide.png|i.imgur.com/iAZgyIy.guide.png]]
[[File:cmd_drag_folder2.guide.png|i.imgur.com/iAZgyIy.png]]


With the command prompt window selected, press the <code>Home</code> key or hold the <code>Left Arrow</code> on the keyboard to change the cursor to the position furthest to the left.
With the command prompt window selected, press the <code>Home</code> key or hold the <code>Left Arrow</code> on the keyboard to change the cursor to the position furthest to the left.


[[File:cmd_drag_folder3.guide.png|i.imgur.com/S91EYIk.guide.png]]
[[File:cmd_drag_folder3.guide.png|i.imgur.com/S91EYIk.png]]


Enter <code>cd</code> and a single space.
Enter <code>cd</code> and a single space.


[[File:cmd_drag_folder4.guide.png|i.imgur.com/5rF1tmX.guide.png]]
[[File:cmd_drag_folder4.guide.png|i.imgur.com/5rF1tmX.png]]


Press <code>Enter</code>.
Press <code>Enter</code>.


[[File:cmd_drag_folder5.guide.png|i.imgur.com/OsNtdKK.guide.png]]
[[File:cmd_drag_folder5.guide.png|i.imgur.com/OsNtdKK.png]]


The <code>cd</code> stands for <code>current directory</code> and using it has changed the current directory of the command prompt window to the extracted path of <code>Avdump2CL.exe</code>.
The <code>cd</code> stands for <code>current directory</code> and using it has changed the current directory of the command prompt window to the extracted path of <code>Avdump2CL.exe</code>.
Line 256: Line 256:
It is possible to verify <code>Avdump2CL.exe</code> is in the current directory by listing the directory contents or checking to see if the file itself is present. List the direct contents using <code>dir</code>, or, for Linux, <code>ls</code>.
It is possible to verify <code>Avdump2CL.exe</code> is in the current directory by listing the directory contents or checking to see if the file itself is present. List the direct contents using <code>dir</code>, or, for Linux, <code>ls</code>.


[[File:cmd_drag_folder6.guide.png|i.imgur.com/uLa3xKM.guide.png]]
[[File:cmd_drag_folder6.guide.png|i.imgur.com/uLa3xKM.png]]


Or check for the executable directly by typing the first few characters <code>av</code> and using <code>Tab</code> to cycle through the available options.
Or check for the executable directly by typing the first few characters <code>av</code> and using <code>Tab</code> to cycle through the available options.


[[File:Avdump2cl_help.guide.png|i.imgur.com/jUOqCpk.guide.png]]
[[File:Avdump2cl_help.guide.png|i.imgur.com/jUOqCpk.png]]


Running <code>Avdump2CL.exe</code> without any options will list many available options.
Running <code>Avdump2CL.exe</code> without any options will list many available options.
Line 266: Line 266:
Running <code>Avdump2CL.exe --help</code> will list all of the available options.
Running <code>Avdump2CL.exe --help</code> will list all of the available options.


[[File:Avdump2cl_help2.guide.png|i.imgur.com/fAgurLa.guide.png]]
[[File:Avdump2cl_help2.guide.png|i.imgur.com/fAgurLa.png]]


====Generating ed2k Links Using Avdump2 CLI====
====Generating ed2k Links Using Avdump2 CLI====
Line 283: Line 283:
To check what happens when a file or folder is specified but with no processing options, enter `Avdump2cl.exe', and then a space and then drag a file to the command prompt window.
To check what happens when a file or folder is specified but with no processing options, enter `Avdump2cl.exe', and then a space and then drag a file to the command prompt window.


[[File:Avdump2cl_dragTest1.guide.png|i.imgur.com/5vhdUg4.guide.png]]
[[File:Avdump2cl_dragTest1.guide.png|i.imgur.com/5vhdUg4.png]]


The file name with the full path will be automatically populated in the command prompt window.
The file name with the full path will be automatically populated in the command prompt window.
Line 381: Line 381:
At the very bottom, paste the ed2k link from and click on <code>Next</code>.
At the very bottom, paste the ed2k link from and click on <code>Next</code>.


[[File:anidb_AddFile8.png|i.imgur.com/kSgxaZ9.guide.png]]
[[File:anidb_AddFile8.png|i.imgur.com/kSgxaZ9.png]]


Make sure the episode number is correct. If you happen to know the date the file was first distributed, enter it in <code>dd.mm.yyyy</code> format. When the information looks correct, click on <code>Add Files</code>.
Make sure the episode number is correct. If you happen to know the date the file was first distributed, enter it in <code>dd.mm.yyyy</code> format. When the information looks correct, click on <code>Add Files</code>.


[[File:anidb_AddFile9.guide.png|i.imgur.com/WPtxkqC.guide.png]]
[[File:anidb_AddFile9.guide.png|i.imgur.com/WPtxkqC.png]]


Success!
Success!


[[File:anidb_AddFile10.guide.png|i.imgur.com/MCEXDgz.guide.png]]
[[File:anidb_AddFile10.guide.png|i.imgur.com/MCEXDgz.png]]


To verify the stub-entry exists, go back to the Anime page. In the <code>Group Status</code> Section, click on the expand button for the group.
To verify the stub-entry exists, go back to the Anime page. In the <code>Group Status</code> Section, click on the expand button for the group.


[[File:anidb_AddFile11.guide.png|i.imgur.com/TPvgDzm.guide.png]]
[[File:anidb_AddFile11.guide.png|i.imgur.com/TPvgDzm.png]]


This will populate the <code>Episodes</code> section with file entries for that group. In the image below, episode 1 of Log Horizon has 2 file entries for the selected group. The top entry has already had the meta-information filled in by Avdump2. The bottom entry is the stub that was just created.
This will populate the <code>Episodes</code> section with file entries for that group. In the image below, episode 1 of Log Horizon has 2 file entries for the selected group. The top entry has already had the meta-information filled in by Avdump2. The bottom entry is the stub that was just created.


[[File:anidb_AddFile12.guide.png|i.imgur.com/Wf8zsGx.guide.png]]
[[File:anidb_AddFile12.guide.png|i.imgur.com/Wf8zsGx.png]]


* Notice that the audio track, resolution and subtitle information was filled in by Avdump2 automatically for the top file where as this information is not yet correct for the bottom file.
* Notice that the audio track, resolution and subtitle information was filled in by Avdump2 automatically for the top file where as this information is not yet correct for the bottom file.
Line 415: Line 415:
The auth flag has the following syntax:
The auth flag has the following syntax:


<code>Avdump2cl.exe --Auth:[username]:[api_key] [file/folder]</code>
<code>Avdump2cl.exe --Auth=[username]:[api_key] [file/folder]</code>


<code>username</code> in the above command should be subtituted with your AniDB username. The <code>api_key</code> is the character string that was specified in the AniDB profile in Part A. Notice the colon <code>:</code> in between the <code>username</code> and <code>api_key</code>. If following this tutorial, it should be available at <code>C:\Users\User\anidb_apiKey.txt</code> or <code>C:\Users\User\Desktop\anidb_apiKey.txt</code>. Copy it and right-click paste it into the command prompt:
<code>username</code> in the above command should be subtituted with your AniDB username. The <code>api_key</code> is the character string that was specified in the AniDB profile in Part A. Notice the colon <code>:</code> in between the <code>username</code> and <code>api_key</code>. If following this tutorial, it should be available at <code>C:\Users\User\anidb_apiKey.txt</code> or <code>C:\Users\User\Desktop\anidb_apiKey.txt</code>. Copy it and right-click paste it into the command prompt:


[[File:Avdump2cl_auth1.guide.png|i.imgur.com/GfGPGUW.guide.png]]
[[File:Avdump2cl_auth1.guide.png|i.imgur.com/GfGPGUW.png]]


[[File:Avdump2cl_auth2.guide.png|i.imgur.com/KSSvMjP.guide.png]]
[[File:Avdump2cl_auth2.guide.png|i.imgur.com/KSSvMjP.png]]


Enter a space and then drag and drop the file to add to AniDB into the command prompt window as before:
Enter a space and then drag and drop the file to add to AniDB into the command prompt window as before:


[[File:Avdump2cl_auth3.guide.png|i.imgur.com/LYSmR8t.guide.png]]
[[File:Avdump2cl_auth3.guide.png|i.imgur.com/LYSmR8t.png]]


The command below should be sufficent to submit the meta-data.
The command below should be sufficent to submit the meta-data.


[[File:Avdump2cl_auth4.guide.png|i.imgur.com/c0qq0hp.guide.png]]
[[File:Avdump2cl_auth4.guide.png|i.imgur.com/c0qq0hp.png]]


Press <code>Enter</code>. If it works, the following should appear after processing completes:
Press <code>Enter</code>. If it works, the following should appear after processing completes:


[[File:Avdump2cl_submitVerify.guide.png|i.imgur.com/LIGgXjf.guide.png]]
[[File:Avdump2cl_submitVerify.guide.png|i.imgur.com/LIGgXjf.png]]


The line that says:<br />
The line that says:<br />
Line 444: Line 444:


If you get an error like the following:<br />
If you get an error like the following:<br />
[[File:Avdump2cl_authFail1.guide.png|i.imgur.com/QAqGtbt.guide.png]]
[[File:Avdump2cl_authFail1.guide.png|i.imgur.com/QAqGtbt.png]]


* Double check the API key is correct.
* Double check the API key is correct.
Line 453: Line 453:
If you get an error like the following:
If you get an error like the following:


[[File:Avdump2cl_authFail2.guide.png|i.imgur.com/oN118Ln.guide.png]]
[[File:Avdump2cl_authFail2.guide.png|i.imgur.com/oN118Ln.png]]


* Notice the error is from <code>ACReq.Authentication</code>. This indicates something to do with authentication caused the error.
* Notice the error is from <code>ACReq.Authentication</code>. This indicates something to do with authentication caused the error.
Line 461: Line 461:
Assuming dump submission succeeds, the AniDB page for the file will likely show the following:
Assuming dump submission succeeds, the AniDB page for the file will likely show the following:


[[File:anidb_AddFile12.guide.png|i.imgur.com/Wf8zsGx.guide.png]]
[[File:anidb_AddFile12.guide.png|i.imgur.com/Wf8zsGx.png]]


In other words, while the correct meta-data has been submitted as part of a dump to AniDB, the information for that file has not changed.
In other words, while the correct meta-data has been submitted as part of a dump to AniDB, the information for that file has not changed.
Line 469: Line 469:
For the file above, this is what the information looked like less than 24-hours later:
For the file above, this is what the information looked like less than 24-hours later:


[File:Avdump2cl_submitVerifyComplete.guide.png|i.imgur.com/nwrSeBV.guide.png]
[[File:Avdump2cl_submitVerifyComplete.guide.png|i.imgur.com/nwrSeBV.png]]


==== Automating Avdump2 CLI ====
==== Automating Avdump2 CLI ====
Line 486: Line 486:
Notice that <code>C:\Users\User\Downloads\Log Horizon</code> needs quotation marks <code>&quot; &quot;</code> surrounding it because <code>Log Horizon</code> has a space. As long as there are no spaces, quotation marks do not have to be used. Without quotation marks, <code>Avdump2cl.exe</code> will treat and process all of the files in <code>C:\Users\User\Downloads\Log</code> and also all of the files inside the <code>Horizon</code> folder. Since neither of these folders exist, the commad will fail:
Notice that <code>C:\Users\User\Downloads\Log Horizon</code> needs quotation marks <code>&quot; &quot;</code> surrounding it because <code>Log Horizon</code> has a space. As long as there are no spaces, quotation marks do not have to be used. Without quotation marks, <code>Avdump2cl.exe</code> will treat and process all of the files in <code>C:\Users\User\Downloads\Log</code> and also all of the files inside the <code>Horizon</code> folder. Since neither of these folders exist, the commad will fail:


[[File:Avdump2cl_syntaxFail1.guide.png|i.imgur.com/7wV8R5O.guide.png]]
[[File:Avdump2cl_syntaxFail1.guide.png|i.imgur.com/7wV8R5O.png]]


If using the drag and drop technique instead of copy-paste, quotation marks will automatically be added as appropriate.
If using the drag and drop technique instead of copy-paste, quotation marks will automatically be added as appropriate.
Line 494: Line 494:
An alternative approach is to create a shell script that will invoke <code>Avdump2cl.exe</code> with the correct syntax automatically. If anything bad happens, like authentication or syntax errors, it will be easy to solve because the correct syntax can just be copied from the text file back to a normal command prompt.
An alternative approach is to create a shell script that will invoke <code>Avdump2cl.exe</code> with the correct syntax automatically. If anything bad happens, like authentication or syntax errors, it will be easy to solve because the correct syntax can just be copied from the text file back to a normal command prompt.


Open notepad and copy-paste the following cryptic text into a file called <code>AniDBUpdate.bat</code> or just download it [here].
Open notepad and copy-paste the following cryptic text into a file called <code>AniDBUpdate.bat</code>.


<pre>
<pre>
Line 500: Line 500:
set username=putUsernameHere
set username=putUsernameHere
set api_key=putApiKeyHere
set api_key=putApiKeyHere
set pathToAvdump2=C:\Users\User\Downloads\avdump-gui-2.3.2-portable\appdata\avdump-gui-2.3.2.win32
set pathToAVDump2CL=C:\Users\User\Downloads\avdump-gui-2.3.2-portable\appdata\avdump-gui-2.3.2.win32


set mode=auth
set mode=auth
Line 512: Line 512:
goto usage)
goto usage)


if not exist &quot;%pathToAvdump2%\Avdump2cl.exe&quot; (echo.
if not exist &quot;%pathToAVDump2CL%\Avdump2cl.exe&quot; (echo.
echo  &quot;%pathToAvdump2%\Avdump2cl.exe&quot; does not exist
echo  &quot;%pathToAVDump2CL%\Avdump2cl.exe&quot; does not exist
goto usage)
goto usage)
if /i &quot;%username%&quot; equ &quot;putUsernameHere&quot; goto usage
if /i &quot;%username%&quot; equ &quot;putUsernameHere&quot; goto usage
if /i &quot;%api_key%&quot; equ &quot;putApiKeyHere&quot; goto usage
if /i &quot;%api_key%&quot; equ &quot;putApiKeyHere&quot; goto usage


if /i &quot;%mode%&quot; equ &quot;exp&quot; &quot;%pathToAvdump2%\Avdump2cl.exe&quot; --Exp=&quot;%~dp1\ed2k-%~n1.%random%.txt&quot; &quot;%~1&quot; &quot;%~2&quot; &quot;%~3&quot; &quot;%~4&quot; &quot;%~5&quot; &quot;%~6&quot; &quot;%~7&quot; &quot;%~8&quot; &quot;%~9&quot;
if /i &quot;%mode%&quot; equ &quot;exp&quot; &quot;%pathToAVDump2CL%\Avdump2cl.exe&quot; --Exp=&quot;%~dp1\ed2k-%~n1.%random%.txt&quot; &quot;%~1&quot; &quot;%~2&quot; &quot;%~3&quot; &quot;%~4&quot; &quot;%~5&quot; &quot;%~6&quot; &quot;%~7&quot; &quot;%~8&quot; &quot;%~9&quot;
::if /i &quot;%mode%&quot; equ &quot;exp&quot; &quot;%pathToAvdump2%\Avdump2cl.exe&quot; --Exp=&quot;%userprofile%\Desktop\ed2k-Link-%~n1.%random%.txt&quot; &quot;%~1&quot; &quot;%~2&quot; &quot;%~3&quot; &quot;%~4&quot; &quot;%~5&quot; &quot;%~6&quot; &quot;%~7&quot; &quot;%~8&quot; &quot;%~9&quot;
::if /i &quot;%mode%&quot; equ &quot;exp&quot; &quot;%pathToAVDump2CL%\Avdump2cl.exe&quot; --Exp=&quot;%userprofile%\Desktop\ed2k-Link-%~n1.%random%.txt&quot; &quot;%~1&quot; &quot;%~2&quot; &quot;%~3&quot; &quot;%~4&quot; &quot;%~5&quot; &quot;%~6&quot; &quot;%~7&quot; &quot;%~8&quot; &quot;%~9&quot;
if /i &quot;%mode%&quot; equ &quot;auth&quot; &quot;%pathToAvdump2%\Avdump2cl.exe&quot; --Auth=&quot;%username%:%api_key%&quot; --Exp=&quot;%~dp1\ed2k-%~n1.%random%.txt&quot; &quot;%~1&quot; &quot;%~2&quot; &quot;%~3&quot; &quot;%~4&quot; &quot;%~5&quot; &quot;%~6&quot; &quot;%~7&quot; &quot;%~8&quot; &quot;%~9&quot;
if /i &quot;%mode%&quot; equ &quot;auth&quot; &quot;%pathToAVDump2CL%\Avdump2cl.exe&quot; --Auth=&quot;%username%:%api_key%&quot; --Exp=&quot;%~dp1\ed2k-%~n1.%random%.txt&quot; &quot;%~1&quot; &quot;%~2&quot; &quot;%~3&quot; &quot;%~4&quot; &quot;%~5&quot; &quot;%~6&quot; &quot;%~7&quot; &quot;%~8&quot; &quot;%~9&quot;
::if /i &quot;%mode%&quot; equ &quot;auth&quot; &quot;%pathToAvdump2%\Avdump2cl.exe&quot; --Auth=&quot;%username%:%api_key%&quot; --Exp=&quot;%userprofile%\Desktop\ed2k-Link-%~n1.%random%.txt&quot; &quot;%~1&quot; &quot;%~2&quot; &quot;%~3&quot; &quot;%~4&quot; &quot;%~5&quot; &quot;%~6&quot; &quot;%~7&quot; &quot;%~8&quot; &quot;%~9&quot;
::if /i &quot;%mode%&quot; equ &quot;auth&quot; &quot;%pathToAVDump2CL%\Avdump2cl.exe&quot; --Auth=&quot;%username%:%api_key%&quot; --Exp=&quot;%userprofile%\Desktop\ed2k-Link-%~n1.%random%.txt&quot; &quot;%~1&quot; &quot;%~2&quot; &quot;%~3&quot; &quot;%~4&quot; &quot;%~5&quot; &quot;%~6&quot; &quot;%~7&quot; &quot;%~8&quot; &quot;%~9&quot;


goto end
goto end
Line 543: Line 543:


:end
:end


</pre>
</pre>
[[File:AniDBUpdate_1.guide.png|i.imgur.com/3glAjpw.guide.png]]
[[File:AniDBUpdate_1.guide.png|i.imgur.com/3glAjpw.png]]


The three highlighted items need to be changed before using the script. Update the username and API key appropriately. Make sure there are no trailing whitespaces in either the username or api_key. &quot;Name&quot; will work but &quot;Name &quot; will not. Example:
The three highlighted items need to be changed before using the script. Update the username and API key appropriately. Make sure there are no trailing whitespaces in either the username or api_key. &quot;Name&quot; will work but &quot;Name &quot; will not. Example:


[[File:AniDBUpdate_2.guide.png|i.imgur.com/OhfWiuG.guide.png]]
[[File:AniDBUpdate_2.guide.png|i.imgur.com/OhfWiuG.png]]


For the pathToAvdump2 entry, the path should not include a trailing <code>\</code>.
For the pathToAvdump2 entry, the path should not include a trailing <code>\</code>.
Line 562: Line 563:
1) Hardest: Command prompt method: Navigate to the correct directory and type <code>AniDBUpdate.bat</code>.
1) Hardest: Command prompt method: Navigate to the correct directory and type <code>AniDBUpdate.bat</code>.


[[File:AniDBUpdate_cmd.guide.png|i.imgur.com/3N0Sg5f.guide.png]]
[[File:AniDBUpdate_cmd.guide.png|i.imgur.com/3N0Sg5f.png]]


2) Drag and drop method: Drag and drop a file or folder onto the batch file.
2) Drag and drop method: Drag and drop a file or folder onto the batch file.


[[File:AniDBUpdate_drag1.guide.png|i.imgur.com/eLFgKWf.guide.png]]
[[File:AniDBUpdate_drag1.guide.png|i.imgur.com/eLFgKWf.png]]
<br />
<br />
[[File:AniDBUpdate_drag2.guide.png|i.imgur.com/sxIleWJ.guide.png]]
[[File:AniDBUpdate_drag2.guide.png|i.imgur.com/sxIleWJ.png]]


3) Easiest: Send-to method: Use the right-click <code>Send to</code> context menu.
3) Easiest: Send-to method: Use the right-click <code>Send to</code> context menu.


[[File:AniDBUpdate_drag1.guide.png|i.imgur.com/kuUEJsh.guide.png]]
[[File:AniDBUpdate_sendToExample.guide.png|i.imgur.com/kuUEJsh.png]]


For the send-to method to work, the file, or a shortcut to it, must be placed at:<br />
For the send-to method to work, the file, or a shortcut to it, must be placed at:<br />
Line 582: Line 583:
# <code>Windows key + r</code>
# <code>Windows key + r</code>
# <code>Ctrl + v</code> to Paste the above contents
# <code>Ctrl + v</code> to Paste the above contents
## [[File:AniDBUpdate_sendTo1.guide.png|i.imgur.com/Dw7Ckdc.guide.png]]
## [[File:AniDBUpdate_sendTo1.guide.png|i.imgur.com/Dw7Ckdc.png]]
# Press <code>Enter</code>
# Press <code>Enter</code>
# Right-Click - create a new shortcut
# Right-Click - create a new shortcut
## [[File:AniDBUpdate_sendTo2.guide.png|i.imgur.com/VsyL3TV.guide.png]]
## [[File:AniDBUpdate_sendTo2.guide.png|i.imgur.com/VsyL3TV.png]]
# Move the shortcut from where it was created to <code>\SentTo</code>.
# Move the shortcut from where it was created to <code>\SentTo</code>.
## [[File:AniDBUpdate_sendTo3.guide.png|i.imgur.com/iUQCorO.guide.png]]
## [[File:AniDBUpdate_sendTo3.guide.png|i.imgur.com/iUQCorO.png]]
# Rename the shortcut appropriately.
# Rename the shortcut appropriately.


Line 613: Line 614:
# Specify the username and api-key.
# Specify the username and api-key.
# Use the <code>Files</code> and <code>Folder</code> buttons too add files to process.
# Use the <code>Files</code> and <code>Folder</code> buttons too add files to process.
## [[File:Avdump2gui_1.guide.png|i.imgur.com/3ypUEcP.guide.png]]
## [[File:Avdump2gui_1.guide.png|i.imgur.com/3ypUEcP.png]]
# When complete, click start to see what happens.
# When complete, click start to see what happens.
## If/When nothing happens check for authentication errors using <code>Avdump2CL.exe</code> using the instructions provided above.
## If/When nothing happens check for authentication errors using <code>Avdump2CL.exe</code> using the instructions provided above.
# If it works, nothing will happen for a while, and then eventually ed2k links will appear in the ed2k export window. The dump data should have been submitted to AniDB in the background, although there is no way to check.
# If it works, nothing will happen for a while, and then eventually ed2k links will appear in the ed2k export window. The dump data should have been submitted to AniDB in the background, although there is no way to check.
## [[File:Avdump2gui_2.guide.png|i.imgur.com/r52bp7D.guide.png]]
## [[File:Avdump2gui_2.guide.png|i.imgur.com/r52bp7D.png]]


The ed2k links in the export window can now be submitted to AniDB. Detailed instructions for this are provided above.
The ed2k links in the export window can now be submitted to AniDB. Detailed instructions for this are provided above.

Revision as of 11:14, 4 September 2017

Anime DataBase (AniDB) is a website that provides information about Anime.

It keeps track of show information and fansub releases for them. It has some social aspects as well. More info. Databases are only useful if they are updated frequently, so this tutorial is about keeping fansub releases on AniDB up to date.

Note This guide has a lot of theory to help explain how to interface with AniDB. For a more concise guide, please consider: Tutorial:How to Add Files for Dummies!

Introduction

AniDB needs to know 3 things to create a full entry for a release:

  1. Which group (or user) released the file.
  2. The unique hash of the file and file name.
  3. The file metadata (resolution, audio tracks, subtitles, etc).

The Avdump2 utility can be used to automatically update AniDB file entries and will be used later.

  • The release group should be associated with each file when creating an entry for it.
    • Non-offical, or files that are not distributed, should not be added.
    • Release group examples: Horrible Subs, Kametsu, and Doki.
  • Before creating an entry for a file, the unique ed2k hash must first be calculated because the ed2k hash will be used in identifying the file.
  • The ed2k hash for the unique identifier can be generated by using Avdump2, or any other program that can generate ed2k hashes.
  • The file's metadata should be updated using the Avdump2 tool.

And so, it is convenient to use the Avdump2 tool to both generate the unique identifier and also update file metadata.

Additional Resources:
wiki/Main_Page
wiki/Auto-creqing
wiki/Avdump2

Prerequisites

  1. Obtain a file to add to AniDB.
    1. The group name is usually present in the file name or description.
  2. Create an AniDB account.
  3. Login and verify that account.

Creating an API Key

Theory

At some point, meta-information for files should be submited using Avdump2. That meta-information is initially associated with the user account that made the submission. While users normally enter usernames/passwords for authentication, Avdump2 needs a unique string of characters to update meta-data. In this context, the string of characters that authenticates a user utilizing Avdump2 is known as an API Key or a UDP API Key.

UDP API keys can be specified in the user profile section on AniDB.net.

Procedure

Log in to AniDB
On the left navigation pane, at the bottom is a section labeled Account. Click on Settings.

i.imgur.com/fEqwtnZ.png

Under profile, in the main navigation window, there are tabs. Click on the one that says Account (highlighted for emphasis).

i.imgur.com/maGR6jL.png

There should be a section called UDP API Key with two fields, one with a label and another empty one.

i.imgur.com/j9B4eSr.png

Any alphanumeric (a-z, A-Z, 0-9) character sequence no longer than 32 characters will work for the API key. For the purposes of this tutorial GRC's Perfect Passwords will be used.

Open a new tab in the web browser and go to GRC's Perfect Passwords page.

In the last box of characters labeled a-z, A-Z, 0-9, highlight 20-30 characters as shown below.

Then copy the selected characters to the clipboard.

  • Right-Click - Copy
  • Ctrl + c

i.imgur.com/3qlV9iu.png

Change tabs back to AniDB's page.

In the empty field under the UDP API Key, right-click and select Paste. Alternatively: Ctrl + v.
i.imgur.com/3V61Mo2.png

i.imgur.com/q5yZPHa.png

Click on the Apply button at the bottom. It should be right above Back.
i.imgur.com/6761Qg3.png
The UDP API Key field should turn into asterisks (*) to show that it has saved it properly.
i.imgur.com/l9OzPgu.png
The API key should also be saved for use with Avdump2 later on, so lets save it to notepad.

Windows key or Click on the start menu and type in notepad.

i.imgur.com/juAtU1M.png

Save the file as something descriptive or as anidb_apiKey.txt in your user profile folder (C:\Users\User) or desktop (C:\Users\User\Desktop).

  • File - Save As...
  • Ctrl + s

Changes to the API key are updated immediately server-side but old entries are cached for an unspecified amount of time, usually less than 30 minutes. Attempting to use the new key before the old key has been removed from the cache will produce this error in the Avdump2cl.exe:

i.imgur.com/SAZIZt8.png

The Avdump2 GUI will simply not respond when authentication fails. More on this later.

Dealing With Groups

Theory

Every file entry should be associated with a release group. The group name or tag is usually in the file name, usually in brackets [ ]. It is important to identify the release group and to verify the group already exists in AniDB.

Examples:

Filename Group Name or [Tag]
[Yuki] Log Horizon - 01 (BD 1080p HEVC Dual-Audio AAC) [2D099D6D].mkv Yuki
Log Horizon - 01 (1080p) BD x265 10-bit (DualAudio) AC3 AAC [KoTuWa].mkv KoTuWa
[ReinForce] Log Horizon - 01 (BDRip 1920x1080 x264 FLAC).mkv ReinForce
[JacobSwaggedUp] Log Horizon - 01 (BD 1280x720).mp4 JacobSwaggedUp
Log.Horizon.S01E01.720p-Hi10p.BluRay.AAC2.0-CTR.[B73B6592].mkv CTR
{AnimeServ.NET} Log Horizon 01 (Blu-ray)(1920x1080 x264 AAC).mp4 AnimeServ.Net
[RHxUHA-WING]Log_Horizon_S1[01][BIG5][720P].mp4 RHxUHA-WING
[BDMV][150724] Log Horizon - Vol.1 n/a
(Shin-Raw) Log Horizon 01 720p (HEVC-HEAAC) [7F99A1E7].mp4 Shin-Raw

For Anime, most groups put their names in brackets [ ] but not always. Group names like DVDISO, RawDVD, BDMV, Anime BD, RAW, R2RAW are keywords that indicate a group is not associated with the upload, usually for uploading unmodified content.

When there is a - or & in the group name, that sometimes means it is a joint release between 2 or more groups. Joint releases are also known as "virtual" releases in AniDB terminology.

In an example above, RHxUHA-WING may be a single group's name or it may be 2 different groups, RHxUHA and WING. Read the description in the download page to find out or search AniDB.

Verify the group exists by searching for it on AniDB.

Procedure

Open Anime DataBase (AniDB).

At the top right next to Search change the search type from all to group.

i.imgur.com/4U31JYW.png

Enter the group name found in the filename and click on Search. In the example below, Doki is used as an example of a group (highlighted for emphasis).

i.imgur.com/XIR5058.png

Click on the group name in the Name column. In the below example it would be Doki Fansubs.

i.imgur.com/aJudr9s.png

Only if the group does not exist, create it. Before actually adding a group, read this and this.

For the purposes of this tutorial, it will be assumed the group name already exists.

On Using Avdump2

Theory

  • A file entry in AniDB has 2 main components, the entry itself and the associated metadata.
  • AniDB stores metadata information for files that are not yet in the database. This means it is possible to add a file entry and then add the metadata, or alternatively, add the metadata to AniDB and create the file entry later.
  • The metadata and the file entry are normally linked using a unique identifier created from the Ed2k-hash and the filesize.

Thus, to create a file entry in AniDB, the ed2k hash must be known and the group name should be known.

The main purpose of the Avdump2 utility, and its GUI wrapper, is to automate updating AniDB file entries. It does 3 things:

  1. Hash files to identify them (ed2k).
  2. Extract Audio/Video/Subtitle and other media information.
  3. Send that information to the server.

Together, the hash information and the media information are called a "dump," short for metadata dump or file dump.

This tutorial will cover creating files associated with a release on AniDB using their ed2k identifier also submitting dumps.

Installation

The description is missing or severely incomplete.
If you can, please help by explaining it.

Download the portable GUI version, direct, (it has both the CLI and GUI) and extract it to C:\Users\User\Downloads. See this random 7-Zip Tutorial. Alternative MSI installer.

For the purposes of this tutorial, it will be assumed the CLI tool is at:
C:\Users\User\Downloads\avdump-gui-2.3.2-portable\appdata\avdump-gui-2.3.2.win32\Avdump2CL.exe
And the GUI tool is available at:
C:\Users\User\Downloads\avdump-gui-2.3.2-portable\Avdump2gui.exe

  • Avdump2CL.exe is a non-interactive program with a command line interface (CLI).
    • It can export ed2k links that can be used to create file entries on AniDB using the --ExportEd2kLinks flag (short form: --Exp).
    • it can also submit metadata dumps for processing. This is done using the --Authentication flag (short form: --Auth) with a Username/UDP API key pair.
  • Avdump2gui.exe is a graphical user interface (GUI) wrapper around the CLI with a subset of the CLI's functionality.
  • Avdump2gui.exe must be used with an API key at all times.

To calculate and export the identifier information, including the ed2k hash, use either the Avdump2 CLI or GUI.

Avdump2 CLI

Command Prompt Introduction

wiki/Avdump2

Start a command prompt:

  • Windows + r - Type cmd.exe and press Enter.
  • Or
  • Windows key - Type cmd.exe and press Enter.

i.imgur.com/zV1Hyk3.png

i.imgur.com/A3nbNdc.png

Let's change the current path to C:\Users\User\Downloads\avdump-gui-2.3.2-portable\appdata\avdump-gui-2.3.2.win32 using cd or pushd.

pushd C:\Users\User\Downloads\avdump-gui-2.3.2-portable\appdata\avdump-gui-2.3.2.win32

Or:

Open an explorer window to: C:\Users\User\Downloads\avdump-gui-2.3.2-portable\appdata\avdump-gui-2.3.2.win32 and drag and drop the folder icon on the top left of the address bar to the command prompt window.

i.imgur.com/lZGLh8B.png

This will populate the command prompt window with the path to the folder automatically, as shown below. This technique can also be used for individual files.

i.imgur.com/iAZgyIy.png

With the command prompt window selected, press the Home key or hold the Left Arrow on the keyboard to change the cursor to the position furthest to the left.

i.imgur.com/S91EYIk.png

Enter cd and a single space.

i.imgur.com/5rF1tmX.png

Press Enter.

i.imgur.com/OsNtdKK.png

The cd stands for current directory and using it has changed the current directory of the command prompt window to the extracted path of Avdump2CL.exe.

It is possible to verify Avdump2CL.exe is in the current directory by listing the directory contents or checking to see if the file itself is present. List the direct contents using dir, or, for Linux, ls.

i.imgur.com/uLa3xKM.png

Or check for the executable directly by typing the first few characters av and using Tab to cycle through the available options.

i.imgur.com/jUOqCpk.png

Running Avdump2CL.exe without any options will list many available options.

Running Avdump2CL.exe --help will list all of the available options.

i.imgur.com/fAgurLa.png

Generating ed2k Links Using Avdump2 CLI

The syntax of Avdump2CL.exe is:

Avdump2CL.exe [--options] [file/folder] [file/folder]

This means that Avdump2CL.exe takes some options and also one or more file or folder paths. The options will specify the type of processing and what file or folder to process.

For the purproses of this tutorial, there is a file named:
[Yuki] Log Horizon - 01 (BD 720p HEVC Dual-Audio AAC) [F8708ABE].mkv
And this file has been placed in:
C:\Users\User\Downloads\Log Horizon

To check what happens when a file or folder is specified but with no processing options, enter `Avdump2cl.exe', and then a space and then drag a file to the command prompt window.

i.imgur.com/5vhdUg4.png

The file name with the full path will be automatically populated in the command prompt window.

i.imgur.com/NiAdL0h.png

Press Enter.

i.imgur.com/8ShIUUC.png

So Avdump2cl.exe complains that no processing options has been specified, so there is nothing to do. So let's give it something to do.

We are trying to use this program to extract ed2k hash information to create a new release on AniDB. That is done using the --ExportEd2kLinks option, or --Exp for short.

The syntax is: Avdump2cl.exe --Exp=[ed2kFileName] [file/folder]

When running the actual command, the file/folder section should be substituted for the actual file or folder name as in the previous command. ed2kFileName should be substituted for a text file name, like ed2k.txt. An example of these substitutions is shown below.

Let's run the command and see what happens.

  • i.imgur.com/Ln9BUxg.png



  • i.imgur.com/PbQTZIE.png

Avdump2cl.exe seems to have processed the file and created a text file called ed2k.txt in its current directory. The file contains one line of contents:

ed2k://|file|[Yuki] Log Horizon - 01 (BD 720p HEVC Dual-Audio AAC) [F8708ABE].mkv|484345397|C33743B735BF1B282B185E1B2E611270|/

This is what the ed2k links used by AniDB look like. After the protocol specifier (ed2k://), is the file keyword, the filename, the file size, and then finally the ed2k hash.

The file size 484345397 is in raw bytes. 484345397 divided by 1024 is 472,993.55 which is the size shown in explorer:

i.imgur.com/2iSZvNI.png

C33743B735BF1B282B185E1B2E611270 happens to be the ed2k hash of this specific file. Every file will have a different ed2k hash.

Let's inform AniDB that this file exists using the ed2k link.

Adding File Entries to AniDB

wiki/Mass_add:Files

Open a web browser and login to anidb.net .

Go to the entry of the Anime in AniDB you want to add a release for. This can be done by using the search feature.

At the top right, enter the name of the Anime. For the purposes of this tutorial the series name is Log Horizon. Change the content type to anime and then click on Search.

i.imgur.com/Wk4zyUT.png

Log Horizon has multiple seasons, so each of them are displayed. Click on the correct season.

i.imgur.com/uoH02cr.png

Scroll down to the Group Status section. Click on the + Add New Release button.

i.imgur.com/KWs7Dmp.png

This should bring up the mass add files page.

i.imgur.com/V9JfUW3.png

Set the group, source, release date, quality, track, and language options.

wiki/How_to_get_started_with_creqing

Let's start with the group. Enter the group name and click on Search.

i.imgur.com/9lnDewj.png

The group name should change and have a drop down menu. Be sure to select the correct group name, identified above in Part B. For the purposes of this tutorial, the correct group name is Yuki Subs [YukinoAi].

i.imgur.com/d5pk8fe.png

Change the template from manual to the most appropriate setting. [Yuki] Log Horizon - 01 (BD 720p HEVC Dual-Audio AAC) [F8708ABE].mkv is labeled as Dual-Audio so the dual template should be used. For most fansub releases with only a single japanese audio track and subtitles, the fansub template should be used instead.

i.imgur.com/1iOomzC.png

Select source and quality of the file:

Source Quality
DVD/BD very high
DTV high
VHS low

If you happen to know any more information about the file, like if the CRC32 of the file matches the official source, enter it. When in doubt, leave that field unmodified. Audio and subtitle track information can usually be left alone alone because that information will be updated later when the meta-data dump uploaded to AniDB becomes associated with the file entry.

At the very bottom, paste the ed2k link from and click on Next.

i.imgur.com/kSgxaZ9.png

Make sure the episode number is correct. If you happen to know the date the file was first distributed, enter it in dd.mm.yyyy format. When the information looks correct, click on Add Files.

i.imgur.com/WPtxkqC.png

Success!

i.imgur.com/MCEXDgz.png

To verify the stub-entry exists, go back to the Anime page. In the Group Status Section, click on the expand button for the group.

i.imgur.com/TPvgDzm.png

This will populate the Episodes section with file entries for that group. In the image below, episode 1 of Log Horizon has 2 file entries for the selected group. The top entry has already had the meta-information filled in by Avdump2. The bottom entry is the stub that was just created.

i.imgur.com/Wf8zsGx.png

  • Notice that the audio track, resolution and subtitle information was filled in by Avdump2 automatically for the top file where as this information is not yet correct for the bottom file.
  • Under the Hash column, there is an icon AU overlayed and a checkmark. This means a the file was verified by Avdump2.
  • The bottom file has CRC overlayed with a checkmark. That means the entry has been marked to indicate that the CRC for the file, matches the official one provided by the release group.
  • So the top file has not been marked as having a verified CRC and the bottom one has not had its metadata updated by Avdump2. Let's fix the metadata.

Back in command prompt world...

Adding Dumps Using Avdump2 CLI

So, the idea is to use Avdump2cl.exe to send a metadata dump to the server. This can be done using the --Authentication flag, or --Auth for short. The auth flag instructs Avdump2cl.exe to attempt to authenticate with AniDB servers. If authentication fails, Avdump2cl.exe will print an error message and stop. If successful, Avdump2cl.exe will process the file and attempt to send the dump to AniDB servers.

Note: Please note that all data sent to the server will be logged using IP and user id. If you would like to check what data will be submitted to the server after authentication, run the following command:
Avdump2cl.exe -ca [file/folder]

The auth flag has the following syntax:

Avdump2cl.exe --Auth=[username]:[api_key] [file/folder]

username in the above command should be subtituted with your AniDB username. The api_key is the character string that was specified in the AniDB profile in Part A. Notice the colon : in between the username and api_key. If following this tutorial, it should be available at C:\Users\User\anidb_apiKey.txt or C:\Users\User\Desktop\anidb_apiKey.txt. Copy it and right-click paste it into the command prompt:

i.imgur.com/GfGPGUW.png

i.imgur.com/KSSvMjP.png

Enter a space and then drag and drop the file to add to AniDB into the command prompt window as before:

i.imgur.com/LYSmR8t.png

The command below should be sufficent to submit the meta-data.

i.imgur.com/c0qq0hp.png

Press Enter. If it works, the following should appear after processing completes:

i.imgur.com/LIGgXjf.png

The line that says:
ACReq( Done: 0 Todo: 1 Failed: 0 Pending: 0 )
Means that processing has finished and Avdump2cl.exe will attempt to upload the dump.

The line that says:
ACReq( Done: 1 Todo: 0 Failed: 0 Pending: 0)
Means the server has accepted the data from Avdump2cl.exe and will store it for later processing. Success!

If you get an error like the following:
i.imgur.com/QAqGtbt.png

  • Double check the API key is correct.
  • The API key being used should be exactly the same one that was entered in the user profile page.
  • UDP API keys should also be alphanumeric and no longer than 32-characters. Keys longer than 32 characters may get trunkated to 32.
  • Since UDP API keys are cached, changing API keys will take some time to clear, usually less than 30 minutes. Attempting to authenticate before that will result in the above error, even if using the correct key and syntax. So wait 30 minutes and try again basically.

If you get an error like the following:

i.imgur.com/oN118Ln.png

  • Notice the error is from ACReq.Authentication. This indicates something to do with authentication caused the error.
  • In the above command, that is due to a syntax error in the --Auth switch. The correct syntax is --Auth=username:api_key but in the above command the username is missing.
  • Press the up arrow key to bring up the previous command in the command prompt window. Then fix the syntax and run the command again. It should then work.

Assuming dump submission succeeds, the AniDB page for the file will likely show the following:

i.imgur.com/Wf8zsGx.png

In other words, while the correct meta-data has been submitted as part of a dump to AniDB, the information for that file has not changed.

This is normal. There is a delay for certain submissions to AniDB. The next section contains more information about how change requests work but for now just know there is a delay and the information will be automatically updated later.

For the file above, this is what the information looked like less than 24-hours later:

i.imgur.com/nwrSeBV.png

Automating Avdump2 CLI

So far, we have added a single file entry and submitted the associated dump for processing. However, Log Horizon S1 has more than 1 episode. Updating each episode this way, by running Avdump2cl.exe twice, once to create the ed2k link and a second time to submit the dump data, would take an excessively long time. Avdump2cl supports combing different flags together into one command:

Avdump2cl.exe --Auth=[username]:[api_key] --Exp=[filename] [file/folder]

If the above command syntax is used on a file, Avdump2cl.exe will authenticate with AniDB servers, then if successful, will process the file, submitting the meta-data to AniDB and then export the ed2k link to a file. This means we can run half the number of commands and still get the output needed to update AniDB!

There is another thing to notice about that syntax. At the end, it says file/folder meaning that Avdump2cl.exe also supports specifying a folder instead of individual files. If a folder is specified, like say: C:\Users\User\Downloads\Log Horizon then Avdump2cl.exe will process every file inside of that folder, generating ed2k links for each file.

With the above information, the actual command to run would be:
Avdump2cl.exe --Auth=YukinoAi:uFEV55lknCwglqdRp1jte36NQ --Exp=Avdump2cl-ed2k-Links.txt "C:\Users\User\Downloads\Log Horizon"

Notice that C:\Users\User\Downloads\Log Horizon needs quotation marks " " surrounding it because Log Horizon has a space. As long as there are no spaces, quotation marks do not have to be used. Without quotation marks, Avdump2cl.exe will treat and process all of the files in C:\Users\User\Downloads\Log and also all of the files inside the Horizon folder. Since neither of these folders exist, the commad will fail:

i.imgur.com/7wV8R5O.png

If using the drag and drop technique instead of copy-paste, quotation marks will automatically be added as appropriate.

So, running the above command with proper quotation marks will work. The ed2k links generated in the text file can be added to AniDB using the Mass Add page as shown above. However, having to worry about syntax is cumbersome, as is starting a command prompt. Is there not a better way?

An alternative approach is to create a shell script that will invoke Avdump2cl.exe with the correct syntax automatically. If anything bad happens, like authentication or syntax errors, it will be easy to solve because the correct syntax can just be copied from the text file back to a normal command prompt.

Open notepad and copy-paste the following cryptic text into a file called AniDBUpdate.bat.

@echo off
set username=putUsernameHere
set api_key=putApiKeyHere
set pathToAVDump2CL=C:\Users\User\Downloads\avdump-gui-2.3.2-portable\appdata\avdump-gui-2.3.2.win32

set mode=auth
::mode can be either exp or auth

if /i "%~1" equ "" (goto usage)
if /i "%~1" equ "?" (goto usage)
if /i "%~1" equ "/?" (goto usage)
if not exist "%~1" (echo.
echo   "%~1" does not exist
goto usage)

if not exist "%pathToAVDump2CL%\Avdump2cl.exe" (echo.
echo   "%pathToAVDump2CL%\Avdump2cl.exe" does not exist
goto usage)
if /i "%username%" equ "putUsernameHere" goto usage
if /i "%api_key%" equ "putApiKeyHere" goto usage

if /i "%mode%" equ "exp" "%pathToAVDump2CL%\Avdump2cl.exe" --Exp="%~dp1\ed2k-%~n1.%random%.txt" "%~1" "%~2" "%~3" "%~4" "%~5" "%~6" "%~7" "%~8" "%~9"
::if /i "%mode%" equ "exp" "%pathToAVDump2CL%\Avdump2cl.exe" --Exp="%userprofile%\Desktop\ed2k-Link-%~n1.%random%.txt" "%~1" "%~2" "%~3" "%~4" "%~5" "%~6" "%~7" "%~8" "%~9"
if /i "%mode%" equ "auth" "%pathToAVDump2CL%\Avdump2cl.exe" --Auth="%username%:%api_key%" --Exp="%~dp1\ed2k-%~n1.%random%.txt" "%~1" "%~2" "%~3" "%~4" "%~5" "%~6" "%~7" "%~8" "%~9"
::if /i "%mode%" equ "auth" "%pathToAVDump2CL%\Avdump2cl.exe" --Auth="%username%:%api_key%" --Exp="%userprofile%\Desktop\ed2k-Link-%~n1.%random%.txt" "%~1" "%~2" "%~3" "%~4" "%~5" "%~6" "%~7" "%~8" "%~9"

goto end
:usage
echo.
echo   OMG^! Hi^!^!^!  Usage Help:
echo.
echo   %~nx0 can be used to automate usage of Avdump2cl.exe
echo   Please update "username" and "api_key" before using %~nx0.
echo.   
echo   CLI Usage: 
echo       %~nx0 "C:\Users\User\Downloads\Log Horizon"
echo       %~nx0 "C:\Users\User\Downloads\Log Horizon\episode01.mkv"
echo.
echo   Drag and drop also works.
echo.
echo   For "right-click Send to" functionality, copy a shortcut to:
echo   "%appdata%\..\roaming\Microsoft\Windows\SendTo"
echo.
pause

:end


i.imgur.com/3glAjpw.png

The three highlighted items need to be changed before using the script. Update the username and API key appropriately. Make sure there are no trailing whitespaces in either the username or api_key. "Name" will work but "Name " will not. Example:

i.imgur.com/OhfWiuG.png

For the pathToAvdump2 entry, the path should not include a trailing \.

Example:

  • C:\avdump-gui-2.3.2-portable will work.
  • C:\avdump-gui-2.3.2-portable\ will not work.

After entering the username and the UDP API key, here are 3 ways to run the above text file:

1) Hardest: Command prompt method: Navigate to the correct directory and type AniDBUpdate.bat.

i.imgur.com/3N0Sg5f.png

2) Drag and drop method: Drag and drop a file or folder onto the batch file.

i.imgur.com/eLFgKWf.png
i.imgur.com/sxIleWJ.png

3) Easiest: Send-to method: Use the right-click Send to context menu.

i.imgur.com/kuUEJsh.png

For the send-to method to work, the file, or a shortcut to it, must be placed at:
C:\Users\Username\AppData\Roaming\Microsoft\Windows\SendTo
To open this folder automatically, paste the following into an explorer address bar or Windows key + r
"%appdata%\..\roaming\Microsoft\Windows\SendTo"

  1. Ctrl + c to copy: "%appdata%\..\roaming\Microsoft\Windows\SendTo"
  2. Windows key + r
  3. Ctrl + v to Paste the above contents
    1. i.imgur.com/Dw7Ckdc.png
  4. Press Enter
  5. Right-Click - create a new shortcut
    1. i.imgur.com/VsyL3TV.png
  6. Move the shortcut from where it was created to \SentTo.
    1. i.imgur.com/iUQCorO.png
  7. Rename the shortcut appropriately.

With the command prompt and send-to methods:

  • Up to 9 discrete files and folders may be selected
  • When sending a folder, all files within that folder and all subfolders will be processed.

Avdump2 GUI

Avdump2gui.exe is the graphical user interface (GUI) wrapper for Avdump2cl.exe and supports a subset of the features:

Avdump2 GUI Limitations. The GUI:

  • always requires authenticating.
  • will not generate links without specifying a valid username and valid API key pair, every time.
    • Note: This information is forcibly saved across instances.
  • must be deliberately started every time to be used.
  • will not issue an error message when authentication fails and simply not respond.
    • If the GUI does not respond, it is advisable to test for authentication errors using Avdump2CL.exe.
  • requires updating prior to usage.

With these limitations in mind. Launch Avdump2gui to have it update automatically.

  1. Specify the username and api-key.
  2. Use the Files and Folder buttons too add files to process.
    1. i.imgur.com/3ypUEcP.png
  3. When complete, click start to see what happens.
    1. If/When nothing happens check for authentication errors using Avdump2CL.exe using the instructions provided above.
  4. If it works, nothing will happen for a while, and then eventually ed2k links will appear in the ed2k export window. The dump data should have been submitted to AniDB in the background, although there is no way to check.
    1. i.imgur.com/r52bp7D.png

The ed2k links in the export window can now be submitted to AniDB. Detailed instructions for this are provided above.

Understanding AniDB Change Requests (creqs)

The description is missing or severely incomplete.
If you can, please help by explaining it.

AniDB is a user-driven database. A normal way to contribute is to issue change requests (creqs for short), which means that a moderator has to approve suggested changes before they are published. Request links can usually be found on every page that has editable content for logged in users.

  • Except for obvious changes, always describe the reason for changes in the request and/or the source of the information.
  • Be prepared to follow up the requests made. Creqs will be denied if there is no response to moderator questions.

More info:
wiki/How_to_update_or_correct_existing_entries
wiki/How_to_get_started_with_creqing

Avdump2, used above, is AniDB's mechanism to submit automatic change requests (acreqs or auto-creq). These automatic change requests do not always require moderator approval because the information (file-metadata) has been verified programmatically. For auto-creqing:

  • All data sent to the server will be logged with IP and user id.
  • There is no direct connection between data sent to AniDB and creqs generated. The data dumps will just be stored for later processing into creqs.
  • There is no way to check the current status for a dump.
  • Avdump2cl.exe will display a count of the files that have been submitted to the server as output as ACReq ( Done: # [...], but that is all.
  • Usually, it should take at least 24 hours from the moment a file metadata dump has been submited untill the file data actually changes. If any irregularities occur, or when there is too much data pending, it will take more time. The system auto-creqs to add missing tracks within 72 hours.
  • It is possible to dump files currently not in the database. The data is still stored and will be used later if/after the file has been registered.

In other words, when Avdump2 submits meta-data dumps to AniDB, the data itself may get processed into a change request. But first, in order to automatically apply the dumped metadata information to a file, that file must be registered first. The process of submitting ed2k links is that registration process. The metadata dumps themselves also contain the ed2k hash information that serves as the basis to link it to registered files.

To learn more about creqs please check out:

"Adding Data" subsection on wiki/Main_Page

For further help with a problem or just for chatting visit IRC:

Wiki page for IRC: wiki/IRC:anidb
Channel Address: irc://irc.synirc.net/anidb