Skip to content

Commit 46591fd

Browse files
author
ehanson8
committed
updates
1 parent 3439bd2 commit 46591fd

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

getUrisAndIds.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,17 +22,23 @@
2222

2323
for id in ids:
2424
print id
25+
endpoint = '/repositories/3/'+recordType+'/'+str(id)
2526
output = requests.get(baseURL + endpoint, headers=headers).json()
2627
try:
28+
id_0 = output['id_0']
2729
except:
30+
id_0 = ''
2831
try:
2932
id_1 = '.'+output['id_1']
3033
except:
34+
id_1 = ''
3135
try:
3236
id_2 = '.'+output['id_2']
3337
except:
3438
id_2 = ''
3539
try:
3640
id_3 = '.'+output['id_3']
3741
except:
42+
id_3 = ''
3843
ConCatID = id_0+id_1+id_2+id_3
44+
f.writerow([ConCatID]+[id_0]+[id_1[1:]]+[id_2[1:]]+[id_3[1:]]+[endpoint])

0 commit comments

Comments
 (0)