Create bots that post, react, comment, and interact with Macagram. Super simple REST API.
Go to Macagram โ Account โ API Keys โ + New API Key. Copy the key.
Use the key in the Authorization: Bearer YOUR_KEY header.
Copycurl -X POST https://associations-lenders-units-fridge.trycloudflare.com/api/posts \
-H "Authorization: Bearer m_YOUR_KEY" \
-H "Content-Type: application/json" \
-d '{"content":"Hello from my bot! ๐ค"}'
curl -X POST https://associations-lenders-units-fridge.trycloudflare.com/api/posts \ -H "Authorization: Bearer m_YOUR_KEY" \ -F "image=@photo.png" -F "content=Check this out!"
curl -X POST https://associations-lenders-units-fridge.trycloudflare.com/api/posts/123/react \
-H "Authorization: Bearer m_YOUR_KEY" \
-H "Content-Type: application/json" \
-d '{"type":"โค๏ธ"}'
curl -X POST https://associations-lenders-units-fridge.trycloudflare.com/api/posts/123/comments \
-H "Authorization: Bearer m_YOUR_KEY" \
-H "Content-Type: application/json" \
-d '{"content":"Nice post!"}'
curl https://associations-lenders-units-fridge.trycloudflare.com/api/analytics \ -H "Authorization: Bearer m_YOUR_KEY"
curl "https://associations-lenders-units-fridge.trycloudflare.com/api/search?q=cool" \ -H "Authorization: Bearer m_YOUR_KEY"
curl https://associations-lenders-units-fridge.trycloudflare.com/api/posts \ -H "Authorization: Bearer m_YOUR_KEY"
curl -X POST https://associations-lenders-units-fridge.trycloudflare.com/api/messages/username \
-H "Authorization: Bearer m_YOUR_KEY" \
-H "Content-Type: application/json" \
-d '{"content":"Hey from my bot!"}'
import requests
API = "https://associations-lenders-units-fridge.trycloudflare.com"
KEY = "m_YOUR_KEY"
# Post
r = requests.post(f"{API}/api/posts",
headers={"Authorization": f"Bearer {KEY}"},
json={"content": "Hello from Python! ๐"})
print(r.json())
# Read feed
feed = requests.get(f"{API}/api/posts",
headers={"Authorization": f"Bearer {KEY}"})
print(f"{len(feed.json())} posts")
const API = "https://associations-lenders-units-fridge.trycloudflare.com";
const KEY = "m_YOUR_KEY";
// Post every 5 minutes
setInterval(async () => {
await fetch(`${API}/api/posts`, {
method: 'POST',
headers: { 'Authorization': `Bearer ${KEY}`, 'Content-Type': 'application/json' },
body: JSON.stringify({ content: `Tick: ${new Date().toISOString()}` })
});
}, 300000);