@@ -1359,7 +1359,9 @@ def get_guids_for_filenames(self, file_names,api):
13591359 def get_record_for_url (self , url , api ):
13601360 """ Returns the indexd record for a file's storage location URL ('urls' in indexd)
13611361 Example:
1362- exp.get_record_for_url(url=https://icgc.bionimbus.org/index/index/?url=s3://pcawg-tcga-sarc-us/2720a2b8-3f4e-5b6e-9f74-1067a068462a, api=api)
1362+ api='https://icgc.bionimbus.org/'
1363+ url='s3://pcawg-tcga-sarc-us/2720a2b8-3f4e-5b6e-9f74-1067a068462a'
1364+ exp.get_record_for_url(url=url,api=api)
13631365 """
13641366 indexd_endpoint = "{}/index/index/" .format (api )
13651367 indexd_query = "{}?url={}" .format (indexd_endpoint ,url )
@@ -1369,7 +1371,12 @@ def get_record_for_url(self, url, api):
13691371 return index_records
13701372
13711373 def get_guid_for_url (self , url , api ):
1372- """Return the GUID for a file's URL in indexd"""
1374+ """Return the GUID for a file's URL in indexd
1375+ Example:
1376+ api='https://icgc.bionimbus.org/'
1377+ url='s3://pcawg-tcga-sarc-us/2720a2b8-3f4e-5b6e-9f74-1067a068462a'
1378+ exp.get_guid_for_url(url=url,api=api)
1379+ """
13731380 index_records = self .get_record_for_url (url = url ,api = api )
13741381 if len (index_records ) == 1 :
13751382 guid = index_records [0 ]['did' ]
0 commit comments