Skip to content

Instantly share code, notes, and snippets.

@olizilla
Created December 4, 2023 17:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save olizilla/6d2215d8a26dfbc6dc0e0ea4cf4ec779 to your computer and use it in GitHub Desktop.
Save olizilla/6d2215d8a26dfbc6dc0e0ea4cf4ec779 to your computer and use it in GitHub Desktop.
---
title: w3s upload
# w3up-client upload sequence
---
sequenceDiagram 
    Agent ->> w3up: store/add (carCid)
    w3up -->> Agent: signed carURL
    Agent ->> R2: PUT to carURL
    Agent ->> w3up: store/add (indexCarCid)
    w3up -->> Agent: signed indexCarURL
    Agent ->> R2: PUT to indexCarURL
    Agent ->> Claims: assert/parititon(indexCid,[indexCarCid])
    Agent ->> Claims: assert/inclusion(carCid,indexCid)
    Agent ->> Claims: assert/relation(carCid,rootCid,childCid,...)
    Agent ->> Claims: assert/partition(rootCid,[carCid])

    %% when should location claims be made?
    %% Agent ->> Claims: assert/location(carCid,[carURL])
    %% Agent ->> Claims: assert/location(indexCid,[indexURL])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment