Skip to main content

How to Set Up Import Rules

This article is intended for assignors & administrators looking to create rules for games imported into Assignr.

Written by Bibs Leitzmann

What are Import Rules?

Import Rules let you automatically clean up and fill in the details of games that come into Assignr from outside sources — a data feed, the API, or a spreadsheet upload — so they end up matching the leagues, venues, teams, and other details you already use, without you having to fix each game by hand.

Who Import Rules are for.

Import Rules are managed by site administrators (owners) and assignors with access to Site Settings.

They only affect games that come in automatically; games you create yourself in Assignr will have the exact details you select, so Import Rules do not apply.

Why use Import Rules.

Feeds, the API, and spreadsheet imports often only know a game by certain game attributes — e.g. an age group, league, or certain teams. Sometimes those names don’t exactly match what you use elsewhere in Assignr, and/or you want every game from a particular league to always use a specific payor, assignor, or pattern. An Import Rule lets you say: 'When an incoming game looks like this, use these exact details instead.'

Where to find Import Rules.

You can access Import Rules from two places:

  • [Your Name] → Settings → Under API Integration, select Set the Import Rules for New Games.

  • [Your Name] → Integrations → Under Assignr API, select Import Rules.

How to Set Up an Import Rule.

Every Import Rule has two parts:

  1. Matching Criteria — 'When a game looks like this…'

  2. Set These Values — '... then use these exact details.'

1. Select + New Import Rule to add a new rule.

2. Matching Criteria — 'When a game looks like this…'

First, fill in the Matching Criteria.

This is the condition for the rule. You can match on any combination of: League, Venue, Gender, Age Group, Game Type, Home Team, Away Team, Home Team Group, and Away Team Group.

  • Leave a field blank to match any game — you only need to fill in the fields that matter for this particular rule.

  • You can list more than one name per field. If a league sometimes comes through as 'Recreational' and other times as 'Rec,' list both — either one will trigger the rule.

  • Names don’t need to exist yet. You’re describing what the incoming data will look like, not picking from things you’ve already created, so it’s fine to type a name even if that league, team, or venue doesn’t exist in Assignr yet.

  • A game has to match every field you filled in to trigger the rule (though matching just one of the names you listed in a field is enough). For example, if you set League to 'Recreational; and Venue to 'Babylon Elementary,' the rule only applies to Recreational games at Babylon Elementary — not to every Recreational game.

3. Set These Values — '... then use these exact details.'

Next, set the values.

This is what happens once a game matches the criteria you set above. You can set: League, Venue, Gender, Age Group, Game Type, Home Team, Away Team, Assignor, Admin Fee Recipient, Payor, Secondary Payor, and Pattern.

  • Only fill in what you want to control. Anything you leave blank here is left as whatever the incoming data provided.

  • These values always win. Once a rule matches, the values you picked replace whatever the feed, API call, or spreadsheet row said — even if that incoming data looked usable. This is what lets you correct inconsistent source data automatically.

4. Choose Additional Options & Save.

You can opt to:

  1. Apply these rules to spreadsheet imports. Check this if you want this rule to apply to spreadsheet imports (in addition to applying to games that come in via the API or other data feeds).

  2. And/or stop processing additional rules if a game matches this rule. Check this if you want this rule to be the final word for any game it matches — no other rules below it will run for that game, even if they would also match.

Once you've checked the relevant boxes, select Save.

How to Handle the Order of Game Import Rules.

If more than one rule could match the same incoming game, only the first matching rule (top to bottom in your list) is used — the rest are ignored for that game.

Put your more specific rules above your more general ones, and use a rule with no Matching Criteria filled in at all as a catch-all at the bottom, since a blank rule matches every game.

You can reorder your rules by dragging them up or down on the Import Rules page.

Let's Look at an Example of a Game Import Rule.

Say games from your Recreational league always come in from your data feed as 'Recreational' or 'Rec,' and should always be assigned to a specific payor for billing. You could create a rule with:

  • Matching Criteria: League = Recreational, Rec

  • Set These Values: League = Recreational (your official league name), Payor = [Your Billing Payor]

Every incoming game with a league name of 'Recreational' or 'Rec' will now come in already attached to your real 'Recreational' league and the correct payor — no manual cleanup needed.

More on Game Import Rules Logic.

  • A rule needs at least one value set in Set These Values — a rule that doesn’t set anything wouldn’t do anything.

  • If you delete a rule, games that already came in under it keep whatever values were set at the time; only future incoming games are affected.

  • Administrative Fee Recipient and Secondary Payor only appears as an option if those features are enabled for your site.

Did this answer your question?