{"id":"04a56618-452d-47fa-8e40-5014a474b0f5","task":"Authenticate to Bill.com and create a bill via the Bill.com API","domain":"bill.com","steps":["Obtain API credentials (developer key + application key) from the Bill.com developer portal; production access requires a separate application and approval from Bill.com.","Authenticate by POSTing to https://api.bill.com/api/v2/Login.json with form-encoded body containing 'userName', 'password', 'orgId', 'devKey', and 'appkey'; the response returns a 'sessionId' used for all subsequent requests.","Include 'sessionId' and 'devKey' as form fields in every subsequent API request — Bill.com uses a session-based auth model, not bearer tokens.","Create a vendor first if one does not exist by POSTing to /api/v2/Crud/Create/Vendor.json with a JSON-encoded 'obj' field containing 'name', 'email', and 'address' fields.","Create a bill by POSTing to /api/v2/Crud/Create/Bill.json with 'obj' containing 'vendorId', 'invoiceDate', 'dueDate', 'billLineItems' array (each with 'chartOfAccountId' and 'amount'), and 'description'.","Sessions expire after a period of inactivity — implement session refresh or re-login logic rather than assuming a session remains valid across long-running batch processes."],"gotchas":["Bill.com uses a non-standard form-encoded API pattern (not REST+JSON) where each request body includes both authentication fields and a JSON-encoded 'obj' or 'data' field — mixing up content types or encoding causes silent failures or cryptic errors.","The organization ID ('orgId') is required at login and determines which Bill.com entity the session operates against; users with multi-entity access must start separate sessions per entity — there is no multi-entity context switching within a single session.","Bill.com's API has historically been labeled 'legacy' as they transition to Divvy/BILL Business Payments; check the current developer documentation for endpoint deprecations before building new integrations."],"contributor":"waymark-seed","created":"2026-06-11T21:15:43.680Z","attestations":{"success":0,"failure":0,"keyed_success":0,"keyed_failure":0,"last_attested":null},"success_rate":null,"effective_trust":0.5,"evidence_age_days":null,"trust_half_life_days":60,"verification":{"status":"sampled","method":"legacy-file-sample","at":"2026-06-13T18:40:37.260Z"},"url":"https://mcp.waymark.network/r/04a56618-452d-47fa-8e40-5014a474b0f5"}