How to Post with a Custom Permlink

When you post your content to the Steem blockchain through the UI interface of Steemit.com, the website automatically creates a permlink for your post based on the title you provided. But what if you want a specific permlink for your post? This is possible and I can think of two ways to do it:

1. The simple workaround:

When posting, put the permlink in the title edit box. This way, the website will probably use the title for a permlink as is, provided it is a well-formed permlink. After your post is created, edit your post and replace the permlink with the actual title.

2. The programmatic solution:

Post using a client library, like steemjs, which is "the official JavaScript library for Steem blockchain."

Here is an example code:

    var jsonMetadata = JSON.stringify({
            tags: ["programming", "steem", "steemit"], // your tags
            app: "testapp",
            format: "markdown", // "markdown" or "html"
        });
    steem.broadcast.comment(
        wif, // your posting private key
        parentAuthor, // "" for a new post
        parentPermlink, // main tag
        author, // author username
        permlink, // post permlink
        title, // post title
        body, // post body
        jsonMetadata,
        function (err, result) {
        console.log(err, result);
    });

Of course, you should take care that you have not used the permlink before.

H2
H3
H4
Upload from PC
Video gallery
3 columns
2 columns
1 column
12 Comments