New Devs SAFE Launcher API Tutorial

Which shows the crazy amount of demand for a super simple tutorial.

Let’s get this done then :slight_smile:

1 Like

Gotcha. First time working with them. Thought it was more of a language of it’s own, now I see it’s more of a set of tools that you use with any language.

1 Like

EDITTED OP to add essential knowledge section on JSON.

Thinking of turning this into a little website or start a blog post of it or something.

Want it to be a resource for brand new devs to get the basic knowledge to get up and running on creating apps for SAFE in the most streamlined way.

Well, with REST (over HTTP(s)) you could always use curl to do stuff :stuck_out_tongue: . Which for a tutorial for developer isn’t even that bad, as it is “language agnostic” and simple to decipher (and something no one will copy-paste!). They do it at square for their docs, and it is awesome.

3 Likes

I’m going thru the SAFE Dev tutorial and started to play with the Launcher API using Postman; I was actually wondering if anyone has created a Postman collection?
I can otherwise share the collection I’m creating as I study the API, it can perhaps be kept in a shareable location/repo.

6 Likes

I hadn’t even heard of this :blush: and AFAIK it hasn’t been mentioned by anyone on these forums, so yes pleeeease! It looks great and providing something to help others make use of it would be great.

Thank you :slight_smile:

Ok, I will work on adding more requests to the collection and share it here in the next few days.
Last night I managed to send an email (compatible with the sample email app) using just Postman :wink:

1 Like

Postman is great, that’s a great idea

Almost forgot. I’ll play with it too :slight_smile:

I have a Postman collection ready to share with you which contains the requests necessary to send an email, but I don’t know where I should upload it, can you please advise?

1 Like

A github repo probably would work best, perhaps? Nice work, postman is superb for testing API’s and trying stuff out like that. Nice one

2 Likes

Thanks @dirvine. Do you mean within https://github.com/maidsafe or my own repo? (I just don’t how you usually handle something like this, It’s ok for me either way)

If you create your own repo that’s cool. We must at some stage collate links to all of these as we go along. I am not sure should we fork them all under a maidsafe community repo and have folks, including us update the code when the API’s are maturing etc.

Anyway your own will be fine for sure. I may start a thread about some kind of way to collate all of these and seek options etc.

5 Likes

Sounds like he meant just make a repo

EDIT: TIL MaidSafe only hires ninjas :slight_smile:

1 Like

Ok, cool, I’ll do that.

EDIT: I just uploaded it here: https://github.com/bochaco/safe-launcher-api-client

I’ll be adding some explanations of how the requests work and how the environment variables are used for each of them.
For the time being this is how it can be used:

  1. Import the collection and the environment variables into Postman
  2. Set the recipient’s email id in the “recipient-email-id” environment variable
  3. Execute the requests in the following order:
  • POST /auth
  • GET /auth (optional: to verify it was authorized)
  • GET /appendableData/handle
  • GET /appendableData/encryptKey
  • POST /immutableData (edit the body beforehand, if you want to change the email’s content. Note the time is calculated automatically)
  • GET /immutableData (optional: to verify the DataMap’s content)
  • PUT /appendableData/handle
4 Likes

I want to make clear that I am not a ninja :slight_smile: – neither do I believe any other team member would say that about themselves. While MaidSafe insist on hiring qualified people, most people describing themselves with these terms (“ninja”, “guru”, “jedi” or “rock star”) usually are not. Quite the opposite, from my experience in this field I’d say that the more experienced the developer, the more humble they become.

3 Likes

thank you @bochaco, this is awesome!

1 Like

And “experts” are just EX-Perts :stuck_out_tongue:

1 Like

Glad I put “wizard” in my twitter bio, phew :wink:

2 Likes

Thanks @ben!.
I added some detailed description of how the requests make use of the scripts and the environment variables. I referenced them to the API and tutorial pages as well. I’ll try to add more requests to the collection in the next days. I also have to make sure it still works with test network #10.

1 Like