View as Markdown
Xero Accounting icon

Xero Accounting ACTION

Create Employee

Creates a new employee.
  • Action
  • Writes data
  • OAuth
  • SDK
  • MCP

IMPLEMENTATION

Call this tool

Connect a user's Xero Accounting account once, then configure and run Create Employee from your backend or agent.

import { PipedreamClient } from "@pipedream/sdk"

const pd = new PipedreamClient({
  projectId: process.env.PIPEDREAM_PROJECT_ID!,
  clientId: process.env.PIPEDREAM_CLIENT_ID!,
  clientSecret: process.env.PIPEDREAM_CLIENT_SECRET!,
  projectEnvironment: "production",
})

const result = await pd.actions.run({
  id: "xero_accounting_api-xero-accounting-create-employee",
  externalUserId: "{external_user_id}", // any stable ID for this user in your system
  configuredProps: {
    xero_accounting_api: { authProvisionId: "apn_xxxxxxx" },
    tenantId: "Tenant ID",
    firstName: "First Name",
  },
})

console.log(result)

SCHEMA

Inputs

Pipedream supplies the connected account. Your application provides the operation-specific values below. Dynamic inputs are resolved against that user's account.

Create Employee inputs
Property Type Description
tenantId Tenant ID string
Select an organization tenant to use, or provide a tenant ID
Required Dynamic
firstName First Name string
First name of an employee (max length = 255). If an existing employee matches your FirstName and LastName then you will receive an error.
Required
lastName Last Name string
Last name of an employee (max length = 255). If an existing employee matches your FirstName and LastName then you will receive an error.
Required
status Status string
Current status of an employee - see contact status types
Optional
externalLink External Link object
Link to an external resource, for example, an employee record in an external system. You can specify the URL element. The description of the link is auto-generated in the form "Go to <App name>". <App name> refers to the Xero application name that is making the API call.
Optional

REFERENCE

Tool details

Behavior hints are published with the component in the Pipedream registry and surface as MCP tool annotations, so an agent can reason about a tool before it calls it.

Registry key
xero_accounting_api-xero-accounting-create-employee
Version
0.3.4
App
Xero Accounting
Authentication
OAuth
Read-only
No
Destructive
No
Open world
Yes