Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs for passing data to 3DStreet via hash #502

Open
kfarr opened this issue Mar 19, 2024 · 0 comments
Open

docs for passing data to 3DStreet via hash #502

kfarr opened this issue Mar 19, 2024 · 0 comments

Comments

@kfarr
Copy link
Collaborator

kfarr commented Mar 19, 2024

As a user of either 3DStreet viewer or 3dstreet-editor (3dstreet.app) I can pass a URL or extra data as a "hash" symbol from multiple third-party sources.

As a developer of 3DStreet I'd like to be able to clearly understand a user's intent when they load from a third-party service through a standard way of supporting multiple embedded data types and third-party service URLs.

Here is an attempt to document this behavior.

Streetmix Path

https://github.3dstreet.org/#https://streetmix.net/kfarr/3/3dstreet-demo-street
https://3dstreet.app/#https://streetmix.net/kfarr/3/3dstreet-demo-street

3DStreet Scene JSON Path

https://github.3dstreet.org/#https://3dstreet.app/scenes/5f44ac44-d33c-4942-bc8d-3827018bab2f.json
https://3dstreet.app/#/scenes/5f44ac44-d33c-4942-bc8d-3827018bab2f.json

Future services under development:

Bollard Buddy Mapper - Crushed JSON Entities

https://bollard-buddy-ar.glitch.me - sample app
https://bollard-buddy-mapper.glitch.me/?data=%5BIBP*BK1753808557987213M8743762969970703LQ998706N2766571*B.8186489939689636M333N691314697266O63N681301116943*BK30109990388154984S11122584342956543O122168779373169*G1.4485996961593628S25578737258911133O1909589767456055*GQ3R14151334762573S3907907R9124756T931634664535522*GQ64729R50983429S40N5738220214844TR9386301N065*C.5397945N6424866E.782535195350647LQ7445403933525085*CPD%5D*D%2CIA%27~posiJBHtraffic-coneA0CHjersey-barrier-plasticA0D)~rotaJ0P))E~y!0F~z!GsafehitAHtemporary-I(%27mixin!%27Jtion!(%27x!K.0LF-M~y!-0K0N04OL2.PEF0Q0.R00SEKTL1.9%01TSRQPONMLKJIHGFEDCBA*_

Url encoded streetmix JSON (from #500 )

to load from url encoded streetmix json you need:

  1. Url encoded streetmix JSON. JSON can be obtained from the Editor, StreetmixAPIURL parameter in the streetmix-loader component of the #default-street element. String can be encoded through encodeURIComponent func in console or here for example: https://www.urlencoder.org/
  2. Paste encoded string after http://localhost:7001/#streetmix-json: or http://localhost:7001/#3dstreet-json: for 3dstreet data

streetplan via json url (from #498 )

https://github.3dstreet.org/#https://upd.streetplan.net/streets-3d-data/79287
https://3dstreet.app/#https://upd.streetplan.net/streets-3d-data/79287

data url: https://upd.streetplan.net/streets-3d-data/79287
user facing url: https://upd.streetplan.net/MyState/MyOrg/MyProj/79287

streetmix via json url (not supported - should we add this? bike game use case)

https://github.3dstreet.org/#https://streetmix.net/api/v1/streets?namespacedId=3&creatorId=kfarr
https://3dstreet.app/#https://streetmix.net/api/v1/streets?namespacedId=3&creatorId=kfarr

@kfarr kfarr changed the title passing url data to 3DStreet docs for passing data to 3DStreet via hash Apr 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant