Features Pricing Services
Compare
Resources
Contact Start Free Trial
Home/Docs/Managing Agents

Managing Agents

Agents are the people in your sales team who use the Soryk app to place orders for B2B customers and earn commissions. Everything about them — name, email, assigned companies, role, territory, language — lives in one place: Admin → Agents.

Create an agent manually

  1. Go to Admin → Agents and click Create agent.
  2. Fill the modal:
    • Email — unique. Used for login and as the commission attribution key.
    • Name — display name in the app and on payouts.
    • Companies — assign one or more B2B companies (multi-select). Can be edited later.
    • Locale — UI language: EN, IT, ES (the agent app supports more languages, this picks the default).
  3. Click Create. The agent is saved as a soryk_agent metaobject. They cannot log in until you send the magic link.

Bulk import via CSV

For teams of 5 or more, use Admin → Agents → Bulk import.

Template columns

ColumnRequiredFormatNotes
emailYesValid emailValidated against a regex. Invalid rows are reported.
nameYesStringFree text.
company_idsNoComma-separated GIDsMust match gid://shopify/Company/<numericId>.
localeNoen | it | esDefault en.
roleNoagent | managerDefault agent.

Example CSV

email,name,company_ids,locale,role
marco.bianchi@example.com,Marco Bianchi,"gid://shopify/Company/123,gid://shopify/Company/456",it,agent
laura.conti@example.com,Laura Conti,gid://shopify/Company/789,it,manager
sara.romano@example.com,Sara Romano,,en,agent
!

How errors are reported. Rows with invalid emails or wrong-format Company GIDs come back in unresolvedCompanies in the import response. Nothing is half-imported — fix the CSV and re-run. The endpoint is idempotent on email: re-importing the same agent updates fields rather than creating a duplicate.

Invite an agent — magic link

  1. Open the agent's profile (Agents → click row).
  2. Click Send magic link.
  3. Soryk sends an email via Resend with a one-time link. The agent opens it on their phone, gets logged in, and is prompted to install the app from the App Store / Play Store (or use the app in their browser).
i

The send response includes emailDelivered: true|false. If false, the UI surfaces a warning toast — usually a typo'd email or a Resend rate-limit. Re-send after fixing.

Edit a profile

From the agent detail page /agents/[id]:

Assign companies to an agent

An agent can be assigned to many companies. A company can have many assigned agents — that's where commission overrides matter (more on the conflict resolution in Commissions → multi-agent fallback).

  1. Open the agent profile.
  2. In the Companies section, click Add.
  3. Search by name. Select one or many. Save.

From the company side: Companies → [Company] → Agents — the same multi-select editor.

Roles & manager hierarchy

Two roles:

Set up a manager:

  1. Toggle the agent's role to Manager.
  2. In the Managed agents selector, pick the team members reporting to them.
  3. Optionally set a Manager override percent — applied on top of the regular commission for orders the manager personally places.

The setting managerOrderAttribution controls how a manager's order on behalf of a team member is tagged: team_agent (commission goes to the team member) or manager_only (commission goes to the manager).

Territories

Each agent can have a territory definition with five layers:

Country, region and ZIP work out of the box. Circles + polygons require lat/lng on company locations — see the known caveat.

Full walkthrough: Territories & Geo.

Remove an agent

  1. Open the agent profile.
  2. Click Delete agent at the bottom.
  3. Confirm.

What happens:

!

Prefer "Inactive" over delete. Setting active=false revokes login but keeps everything else intact. Delete only when an agent is permanently gone and you don't expect any orders to ever reference their email again.

Best practices

i

One email per human. Don't share an email between two reps — commissions can't be split automatically. If two people work the same territory, give each their own agent and use a manager hierarchy or commission overrides.

i

Use the agent's real personal/work email. Not sales1@yourcompany.com. The magic link goes there, push notifications go there, and audit logs read better. If they leave, you delete or deactivate the account — not the email.

i

Assign companies before sending the invite. An agent who logs in to an empty company list will think the app is broken. Assign at least one before they get the magic link.

Was this helpful?
Edit this page on GitHub