Skip to main content
POST
/
moment
/
create
/
writing
Create a Writing Moment
curl --request POST \
  --url https://api.inprocess.world/api/moment/create/writing \
  --header 'Content-Type: application/json' \
  --data '
{
  "title": "<string>",
  "contract": {
    "address": "<string>",
    "name": "<string>",
    "uri": "<string>"
  },
  "token": {
    "tokenContent": "<string>",
    "createReferral": "<string>",
    "salesConfig": {
      "pricePerToken": "<string>",
      "saleStart": "<string>",
      "saleEnd": "<string>",
      "currency": "<string>"
    },
    "mintToCreatorCount": 123,
    "payoutRecipient": "<string>"
  },
  "account": "<string>",
  "splits": [
    {
      "address": "<string>",
      "percentAllocation": 50
    }
  ],
  "chainId": 8453
}
'
import requests

url = "https://api.inprocess.world/api/moment/create/writing"

payload = {
"title": "<string>",
"contract": {
"address": "<string>",
"name": "<string>",
"uri": "<string>"
},
"token": {
"tokenContent": "<string>",
"createReferral": "<string>",
"salesConfig": {
"pricePerToken": "<string>",
"saleStart": "<string>",
"saleEnd": "<string>",
"currency": "<string>"
},
"mintToCreatorCount": 123,
"payoutRecipient": "<string>"
},
"account": "<string>",
"splits": [
{
"address": "<string>",
"percentAllocation": 50
}
],
"chainId": 8453
}
headers = {"Content-Type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.text)
const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
title: '<string>',
contract: {address: '<string>', name: '<string>', uri: '<string>'},
token: {
tokenContent: '<string>',
createReferral: '<string>',
salesConfig: {
pricePerToken: '<string>',
saleStart: '<string>',
saleEnd: '<string>',
currency: '<string>'
},
mintToCreatorCount: 123,
payoutRecipient: '<string>'
},
account: '<string>',
splits: [{address: '<string>', percentAllocation: 50}],
chainId: 8453
})
};

fetch('https://api.inprocess.world/api/moment/create/writing', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://api.inprocess.world/api/moment/create/writing",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'title' => '<string>',
'contract' => [
'address' => '<string>',
'name' => '<string>',
'uri' => '<string>'
],
'token' => [
'tokenContent' => '<string>',
'createReferral' => '<string>',
'salesConfig' => [
'pricePerToken' => '<string>',
'saleStart' => '<string>',
'saleEnd' => '<string>',
'currency' => '<string>'
],
'mintToCreatorCount' => 123,
'payoutRecipient' => '<string>'
],
'account' => '<string>',
'splits' => [
[
'address' => '<string>',
'percentAllocation' => 50
]
],
'chainId' => 8453
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"strings"
"net/http"
"io"
)

func main() {

url := "https://api.inprocess.world/api/moment/create/writing"

payload := strings.NewReader("{\n \"title\": \"<string>\",\n \"contract\": {\n \"address\": \"<string>\",\n \"name\": \"<string>\",\n \"uri\": \"<string>\"\n },\n \"token\": {\n \"tokenContent\": \"<string>\",\n \"createReferral\": \"<string>\",\n \"salesConfig\": {\n \"pricePerToken\": \"<string>\",\n \"saleStart\": \"<string>\",\n \"saleEnd\": \"<string>\",\n \"currency\": \"<string>\"\n },\n \"mintToCreatorCount\": 123,\n \"payoutRecipient\": \"<string>\"\n },\n \"account\": \"<string>\",\n \"splits\": [\n {\n \"address\": \"<string>\",\n \"percentAllocation\": 50\n }\n ],\n \"chainId\": 8453\n}")

req, _ := http.NewRequest("POST", url, payload)

req.Header.Add("Content-Type", "application/json")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.post("https://api.inprocess.world/api/moment/create/writing")
.header("Content-Type", "application/json")
.body("{\n \"title\": \"<string>\",\n \"contract\": {\n \"address\": \"<string>\",\n \"name\": \"<string>\",\n \"uri\": \"<string>\"\n },\n \"token\": {\n \"tokenContent\": \"<string>\",\n \"createReferral\": \"<string>\",\n \"salesConfig\": {\n \"pricePerToken\": \"<string>\",\n \"saleStart\": \"<string>\",\n \"saleEnd\": \"<string>\",\n \"currency\": \"<string>\"\n },\n \"mintToCreatorCount\": 123,\n \"payoutRecipient\": \"<string>\"\n },\n \"account\": \"<string>\",\n \"splits\": [\n {\n \"address\": \"<string>\",\n \"percentAllocation\": 50\n }\n ],\n \"chainId\": 8453\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.inprocess.world/api/moment/create/writing")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"title\": \"<string>\",\n \"contract\": {\n \"address\": \"<string>\",\n \"name\": \"<string>\",\n \"uri\": \"<string>\"\n },\n \"token\": {\n \"tokenContent\": \"<string>\",\n \"createReferral\": \"<string>\",\n \"salesConfig\": {\n \"pricePerToken\": \"<string>\",\n \"saleStart\": \"<string>\",\n \"saleEnd\": \"<string>\",\n \"currency\": \"<string>\"\n },\n \"mintToCreatorCount\": 123,\n \"payoutRecipient\": \"<string>\"\n },\n \"account\": \"<string>\",\n \"splits\": [\n {\n \"address\": \"<string>\",\n \"percentAllocation\": 50\n }\n ],\n \"chainId\": 8453\n}"

response = http.request(request)
puts response.read_body
{
  "contractAddress": "<string>",
  "tokenId": "<string>",
  "hash": "<string>",
  "chainId": 123
}
{
"status": "error",
"message": "<string>",
"errors": [
{
"field": "<string>",
"message": "<string>"
}
]
}
{
"status": "error",
"message": "<string>",
"errors": [
{
"field": "<string>",
"message": "<string>"
}
]
}

Body

application/json
title
string
required

Title of the writing moment

contract
object
required

Collection target. Provide address to mint on an existing ERC-1155 collection, or provide both name and uri to deploy a new collection in the same request.

token
object
required
account
string
required

Creator's address

splits
object[]

Optional revenue splits configuration. Must have at least 2 recipients and sum to 100%

Minimum array length: 2
chainId
integer
default:8453

Chain ID (optional; defaults to Base mainnet in production and Base Sepolia in preview or development)

Response

Successful response

contractAddress
string
required

The address of the collection (newly created or existing)

tokenId
string
required

The token ID of the created moment

hash
string
required

Transaction hash of the creation operation

chainId
integer
required

Chain ID where the transaction was executed