Quote from: David_H on July 22, 2024, 07:23:06 PMBecause you are asking it to search on the filename. ExtHDD is in the PATH, not the filename (rr52024.cr3).
id : 226011
ts : 45489,823727
tsmd : 0,000000
tsCreated : 2023:10:01T10:22:57.458
tsLastModified : 2023:09:26T09:24:26.0
tsLastWriteBackUtc : 0,000000
tsLastWriteBack : 0,000000
index : 59
folderId : 1719
folder : C:\DSLR\DSLR-RAW\ExtHDD 2508\EOS R5\2023\09\26\
name : _rr52024.cr3
namene : _rr52024
ext : .cr3
fileName : C:\DSLR\DSLR-RAW\ExtHDD 2508\EOS R5\2023\09\26\_rr52024.cr3
size : 53712982
crc : 2044429776
ltid : 3E26B778-AA74-44B1-B3FF-59E58E0D453D
class : image
format : CRW
mimeType : text/plain
lastUpdated : 2023-09-26T11:24:26
lastUpdatedUTC : 2023-09-26T09:24:26
dateTime : 2023-09-26T11:24:25
dateTimeUTC : 2023-09-26T09:24:25
dateTimeOriginal : 2023-09-26T11:24:25
dateTimeLocal : 2023-09-26T11:24:25
dateTimeOffset : 120
offline : False
protected : False
readOnly : False
pending : False
pendingWb : False
width : 8352
height : 5586
longEdge : 8352
shortEdge : 5586
portrait : False
bpp : 24
rating : 2
label :
stackState : 0
stackId : 0
stackColor :
versionState : 0
history : {@{event=}, @{event=}}
gps : @{lat=54,188267; lon=7,883228; alt=38,620000}
collections : {13, 34, 54, 10002...}
roi : @{v=False; t=0,000000; r=1,000000; b=1,000000; l=0,000000}
Quote from: RobiWan on July 22, 2024, 06:43:23 PMOk understand.
let me ask a different question. Why the first one doesn't work and the second one works?PowerShell > (Invoke-WebRequest -Uri "$URI/v1/search/filename?auth_token=&scope=database&pattern=ExtHDD").content
{"files":[],"hiddenByStacks":0}PowerShell > (Invoke-WebRequest -Uri "$URI/v1/search/filename?auth_token=&scope=database&pattern=_rr52024.cr3").content
{"files":[{"id":216011,"ts":45489.813102,"tsmd":0.000000,"tsCreated":"2023:05:04T10:21:38.193","tsLastModified":"2023:05:04T06:00:04.0","tsLastWriteBackUtc":0.000000,"tsLastWriteBack":0.000000,"index":0,"folderId":1714,"folder":"C:\\DSLR\\DSLR-RAW\\ExtHDD 2508\\EOS R5\\2023\\05\\04\\","name":"_rr52024.cr3","namene":"_rr52024","ext":".cr3","fileName":"C:\\DSLR\\DSLR-RAW\\ExtHDD 2508\\EOS R5\\2023\\05\\04\\_rr52024.cr3","size":53537366,"crc":3658268326,"ltid":"2A45C54B-1E54-4A2B-A7B6-D3B78BDE3A15","class":"image","format":"CRW","mimeType":"text/plain","lastUpdated":"2023-05-04T08:00:04","lastUpdatedUTC":"2023-05-04T06:00:04","dateTime":"2023-05-04T08:00:03","dateTimeUTC":"2023-05-04T06:00:03","dateTimeOriginal":"2023-05-04T08:00:03","dateTimeLocal":"2023-05-04T08:00:03","dateTimeOffset":120,"offline":false,"protected":false,"readOnly":false,"pending":false,"pendingWb":false,"width":8352,"height":5586,"longEdge":8352,"shortEdge":5586,"portrait":false,"bpp":24,"rating":2,"label":"","stackState":0,"stackId":0,"stackColor":"","versionState":0,"history":[{"event":{"type":1,"name":"added","id":216011,"id2":0,"dateTime":"2023-11-11T10:07:30","title":"","text":"","user":"robert"}},{"event":{"type":2,"name":"updated","id":216011,"id2":0,"dateTime":"2023-11-11T11:14:12","title":"","text":"","user":"robert"}}],"gps":{"lat":39.862600,"lon":-5.023578,"alt":408.300000},"collections":[13,34,54,10002,11001],"roi":{"v":false,"t":0.000000,"r":1.000000,"b":1.000000,"l":0.000000}},{"id":226011,"ts":45489.823727,"tsmd":0.000000,"tsCreated":"2023:10:01T10:22:57.458","tsLastModified":"2023:09:26T09:24:26.0","tsLastWriteBackUtc":0.000000,"tsLastWriteBack":0.000000,"index":1,"folderId":1719,"folder":"C:\\DSLR\\DSLR-RAW\\ExtHDD 2508\\EOS R5\\2023\\09\\26\\","name":"_rr52024.cr3","namene":"_rr52024","ext":".cr3","fileName":"C:\\DSLR\\DSLR-RAW\\ExtHDD 2508\\EOS R5\\2023\\09\\26\\_rr52024.cr3","size":53712982,"crc":2044429776,"ltid":"3E26B778-AA74-44B1-B3FF-59E58E0D453D","class":"image","format":"CRW","mimeType":"text/plain","lastUpdated":"2023-09-26T11:24:26","lastUpdatedUTC":"2023-09-26T09:24:26","dateTime":"2023-09-26T11:24:25","dateTimeUTC":"2023-09-26T09:24:25","dateTimeOriginal":"2023-09-26T11:24:25","dateTimeLocal":"2023-09-26T11:24:25","dateTimeOffset":120,"offline":false,"protected":false,"readOnly":false,"pending":false,"pendingWb":false,"width":8352,"height":5586,"longEdge":8352,"shortEdge":5586,"portrait":false,"bpp":24,"rating":2,"label":"","stackState":0,"stackId":0,"stackColor":"","versionState":0,"history":[{"event":{"type":1,"name":"added","id":226011,"id2":0,"dateTime":"2023-11-11T10:13:46","title":"","text":"","user":"robert"}},{"event":{"type":2,"name":"updated","id":226011,"id2":0,"dateTime":"2023-11-11T12:34:20","title":"","text":"","user":"robert"}}],"gps":{"lat":54.188267,"lon":7.883228,"alt":38.620000},"collections":[13,34,54,10002,11001],"roi":{"v":false,"t":0.000000,"r":1.000000,"b":1.000000,"l":0.000000}}],"hiddenByStacks":0}
"ExtHDD" is a part of path where many images are stored, so I think I should receive many results back.
I did not say that the API does not work. At the moment I'm trying to get an overview of the whole thing.
PowerShell > (Invoke-WebRequest -Uri "$URI/v1/search/filename?auth_token=&scope=database&pattern=ExtHDD").content
{"files":[],"hiddenByStacks":0}
PowerShell > (Invoke-WebRequest -Uri "$URI/v1/search/filename?auth_token=&scope=database&pattern=_rr52024.cr3").content
{"files":[{"id":216011,"ts":45489.813102,"tsmd":0.000000,"tsCreated":"2023:05:04T10:21:38.193","tsLastModified":"2023:05:04T06:00:04.0","tsLastWriteBackUtc":0.000000,"tsLastWriteBack":0.000000,"index":0,"folderId":1714,"folder":"C:\\DSLR\\DSLR-RAW\\ExtHDD 2508\\EOS R5\\2023\\05\\04\\","name":"_rr52024.cr3","namene":"_rr52024","ext":".cr3","fileName":"C:\\DSLR\\DSLR-RAW\\ExtHDD 2508\\EOS R5\\2023\\05\\04\\_rr52024.cr3","size":53537366,"crc":3658268326,"ltid":"2A45C54B-1E54-4A2B-A7B6-D3B78BDE3A15","class":"image","format":"CRW","mimeType":"text/plain","lastUpdated":"2023-05-04T08:00:04","lastUpdatedUTC":"2023-05-04T06:00:04","dateTime":"2023-05-04T08:00:03","dateTimeUTC":"2023-05-04T06:00:03","dateTimeOriginal":"2023-05-04T08:00:03","dateTimeLocal":"2023-05-04T08:00:03","dateTimeOffset":120,"offline":false,"protected":false,"readOnly":false,"pending":false,"pendingWb":false,"width":8352,"height":5586,"longEdge":8352,"shortEdge":5586,"portrait":false,"bpp":24,"rating":2,"label":"","stackState":0,"stackId":0,"stackColor":"","versionState":0,"history":[{"event":{"type":1,"name":"added","id":216011,"id2":0,"dateTime":"2023-11-11T10:07:30","title":"","text":"","user":"robert"}},{"event":{"type":2,"name":"updated","id":216011,"id2":0,"dateTime":"2023-11-11T11:14:12","title":"","text":"","user":"robert"}}],"gps":{"lat":39.862600,"lon":-5.023578,"alt":408.300000},"collections":[13,34,54,10002,11001],"roi":{"v":false,"t":0.000000,"r":1.000000,"b":1.000000,"l":0.000000}},{"id":226011,"ts":45489.823727,"tsmd":0.000000,"tsCreated":"2023:10:01T10:22:57.458","tsLastModified":"2023:09:26T09:24:26.0","tsLastWriteBackUtc":0.000000,"tsLastWriteBack":0.000000,"index":1,"folderId":1719,"folder":"C:\\DSLR\\DSLR-RAW\\ExtHDD 2508\\EOS R5\\2023\\09\\26\\","name":"_rr52024.cr3","namene":"_rr52024","ext":".cr3","fileName":"C:\\DSLR\\DSLR-RAW\\ExtHDD 2508\\EOS R5\\2023\\09\\26\\_rr52024.cr3","size":53712982,"crc":2044429776,"ltid":"3E26B778-AA74-44B1-B3FF-59E58E0D453D","class":"image","format":"CRW","mimeType":"text/plain","lastUpdated":"2023-09-26T11:24:26","lastUpdatedUTC":"2023-09-26T09:24:26","dateTime":"2023-09-26T11:24:25","dateTimeUTC":"2023-09-26T09:24:25","dateTimeOriginal":"2023-09-26T11:24:25","dateTimeLocal":"2023-09-26T11:24:25","dateTimeOffset":120,"offline":false,"protected":false,"readOnly":false,"pending":false,"pendingWb":false,"width":8352,"height":5586,"longEdge":8352,"shortEdge":5586,"portrait":false,"bpp":24,"rating":2,"label":"","stackState":0,"stackId":0,"stackColor":"","versionState":0,"history":[{"event":{"type":1,"name":"added","id":226011,"id2":0,"dateTime":"2023-11-11T10:13:46","title":"","text":"","user":"robert"}},{"event":{"type":2,"name":"updated","id":226011,"id2":0,"dateTime":"2023-11-11T12:34:20","title":"","text":"","user":"robert"}}],"gps":{"lat":54.188267,"lon":7.883228,"alt":38.620000},"collections":[13,34,54,10002,11001],"roi":{"v":false,"t":0.000000,"r":1.000000,"b":1.000000,"l":0.000000}}],"hiddenByStacks":0}
^$strImageName\.
$strImageName = "pict0980"
$arrImageParts = ((Invoke-WebRequest -Uri "$URI/v1/search/filename?auth_token=&scope=database&pattern=^$strImageName\.&sortby=filename-Asc").Content | convertfrom-json).files
$strImageName = "pict0980.mrw"
$arrImageParts = ((Invoke-WebRequest -Uri "$URI/v1/search/filename?auth_token=&scope=database&pattern=^$strImageName\.&sortby=filename-Asc").Content | convertfrom-json).files
$strImageName = "pict0980\.mrw"
$arrImageParts = ((Invoke-WebRequest -Uri "$URI/v1/search/filename?auth_token=&scope=database&pattern=^$strImageName\.&sortby=filename-Asc").Content | convertfrom-json).files
$strImageName = "C:\\DSLR\\DSLR-RAW\\ExtHDD\ 2501\\Dynax7D\\2006\\09\\17\\pict0980\.mrw"
$arrImageParts = ((Invoke-WebRequest -Uri "$URI/v1/search/filename?auth_token=&scope=database&pattern=^$strImageName\.&sortby=filename-Asc").Content | convertfrom-json).files
$strImageName = "C:\DSLR\DSLR-RAW\ExtHDD 2501\Dynax7D\2006\09\17\pict0980.mrw"
$arrImageParts = ((Invoke-WebRequest -Uri "$URI/v1/search/filename?auth_token=&scope=database&pattern=^$strImageName\.&sortby=filename-Asc").Content | convertfrom-json).files