proc.delete
0.000005

Deletes a stored proc.

Arguments
namerequired
The name of the stored proc to delete.
Return Value
true if the proc was deleted, otherwise false.
something went wrong :(
Deleting a stored proc by name
Setup
authorization=PROCAUTH
require "proc"

client = Proc.connect("PROCAUTH")
const Proc = require("@proc.dev/client");
const client = Proc.connect("PROCAUTH");
client.proc.create.call(name: "za3c2130") {
  client.type.string.truncate(length: 5)
}

client.proc.delete.call(
  name: "za3c2130"
)
client.proc.create(undefined, za3c2130, () => {
  return client.type.string.truncate(undefined, {length: 5});
});

client.proc.delete.call(
  undefined, za3c2130
)
curl "https://proc.run/proc/create?name=za3c2130" --silent \
--header "authorization: bearer $authorization" \
--header "content-type: application/vnd.proc+json" \
--header "accept: text/plain" \
--data '[["$$", "proc", ["{}", ["()", "type.string.truncate", ["$$", "length", ["%%", 5]]]]]]'

curl "https://proc.run/proc/delete?name=za3c2130" --silent --request POST \
--header "authorization: bearer $authorization" \
--header "content-type: text/plain"
 

true


Stuck? Want to chat about an idea? Join the community on Discord.