Skip to content

Instantly share code, notes, and snippets.

Last active November 24, 2022 00:45
What would you like to do?
import re
import requests
endpoint = ""
url= ""
response = requests.get(url)
parse_data = re.finditer(r'"cid":"([a-z0-9]+)"', response.text)
for m in parse_data:
r = + "?arg=" + m[1],)
Copy link

Another method for Unix one-liners.

curl | jq -r .list[].cid | xargs ipfs pin add --progress

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment