Interact with Twenty CRM (self-hosted) via REST/GraphQL.
Interact with your self-hosted Twenty instance via REST and GraphQL.
Create config/twenty.env (example at config/twenty.env.example):
TWENTY_BASE_URL (e.g. https://crm.example.com or http://localhost:3000)TWENTY_API_KEY (Bearer token)Scripts load this file automatically.
REST GET: skills/twenty-crm/scripts/twenty-rest-get.sh "/companies" 'filter={"name":{"ilike":"%acme%"}}&limit=10'
REST POST: skills/twenty-crm/scripts/twenty-rest-post.sh "/companies" '{"name":"Acme"}'
REST PATCH: skills/twenty-crm/scripts/twenty-rest-patch.sh "/companies/<id>" '{"employees":550}'
REST DELETE: skills/twenty-crm/scripts/twenty-rest-delete.sh "/companies/<id>"
GraphQL: skills/twenty-crm/scripts/twenty-graphql.sh 'query { companies(limit: 5) { totalCount } }'
skills/twenty-crm/scripts/twenty-create-company.sh "Acme" "acme.com" 500skills/twenty-crm/scripts/twenty-find-companies.sh "acme" 10/rest/...) and GraphQL (/graphql).401.