Skip to content
Fourohtwo

Use when an agent must publish or unpublish a stored file

1gateway.dev/v1/files/visibility

Use when an agent must publish or unpublish a stored file. Pay from the wallet that uploaded it (USDC on any EVM network in the 402 quote). Input: id, visibility (public or private). Output: the file with its url if now public. Public files download from 1storage.dev without a signature; private ones need /v1/files/sign. Missing file: 404, not charged. Example: ?id=0123456789abcdef0123456789abcdef

BaseMonadPolygonArbitrumSolanaAnswering
GEThttps://1gateway.dev/v1/files/visibility

Uptime100% of 1 check in 30 days

30 days agoToday

Try it

Pays from your browser wallet in USDC on Base or USDG on Robinhood Chain, whichever the endpoint takes. The provider is paid directly; failed calls aren't refunded by Fourohtwo.

The response shows up here.

Call it from an agent

import { createPayer } from "fourohtwo";

// One agent key pays USDC on Base or USDG on Robinhood Chain,
// inside the spending rules you set on Fourohtwo.
const pay = createPayer({ privateKey: process.env.AGENT_KEY });
const res = await pay("https://1gateway.dev/v1/files/visibility?id=0123456789abcdef0123456789abcdef&visibility=public");
console.log(await res.json());

Example input

{
  "id": "0123456789abcdef0123456789abcdef",
  "visibility": "public"
}

More from Agent File Storage