Fluent Commerce Logo
Docs

How Sourcing Profile GraphQL API works

Topic

Author:

Kirill Gaiduk

Changed on:

17 Sept 2025

Overview

The Sourcing Profile GraphQL API allows technical users to manage sourcing logic within the Fluent platform.


Prerequisites

You should have knowledge of:

Sourcing Profile GraphQL API Overview

Author:

Kirill Gaiduk

Changed on:

2 Oct 2025

Overview

This article provides technical users with information about the Sourcing Profile GraphQL API, which enables configuration and querying of Sourcing Profiles within the Fluent Platform.

Key points

  • Specific permissions are required for Sourcing Profile operations
  • Use the `createSourcingProfile` mutation to create new Sourcing Profiles or generate updated versions
  • Activate a profile version with the `activateSourcingProfile` mutation; this sets it to `ACTIVE` and automatically sets the previous `ACTIVE` profile version to `INACTIVE`
  • Retrieve Profiles using the `sourcingProfile` query (single Sourcing Profile by Reference) or `sourcingProfiles` query (multiple, with filters)
  • Every update creates a new version of the Sourcing Profile, ensuring full version history is preserved

What is the Sourcing Profile GraphQL API for?

The Sourcing Profile GraphQL API allows technical users to manage sourcing logic within the Fluent Platform:

  • Create, update, activate, and query Sourcing Profiles
  • Define Primary and Fallback Sourcing Strategies
  • Configure Sourcing Conditions and Criteria within each Sourcing Strategy

Sourcing Profile Management

The following diagram explains the key steps of Sourcing Profile management:

No alt provided

Permissions

The following permissions are required for different operations on Sourcing Profiles:

  • `SOURCINGPROFILE_CREATE`
  • `SOURCINGPROFILE_UPDATE`
  • `SOURCINGPROFILE_VIEW`

Decision Flow

The following diagram explains the Sourcing Profile GraphQL API behavior:

No alt provided

Features

The Sourcing Profile GraphQL API provides the following functionalities:

Create or Update Sourcing Profile

The `createSourcingProfile` mutation creates a Sourcing Profile (or its newer version) for a Retailer:

  • If the provided `ref` is unique, it creates the first version with `ACTIVE` status
  • If a `SourcingProfile` with the same `ref` already exists, it creates a new version with `DRAFT` status

Activate Sourcing Profile

The `activateSourcingProfile` mutation activates a specific version of a Sourcing Profile. When called, it performs the following actions:

  • Sets the specified version status to `ACTIVE`
  • Updates the previously `ACTIVE` version to `INACTIVE`

Get Sourcing Profile

The `sourcingProfile` query retrieves a Sourcing Profile by its Reference:

  • If a version is provided, the query returns that specific version
  • If no version is provided, the query returns the latest available version

Search Sourcing Profiles

The `sourcingProfiles` query retrieves existing Sourcing Profiles and supports multiple filters and pagination. For example, you can use it to:

  • Return active Profiles by applying the `ACTIVE` status filter
  • Review the audit history of inactive versions with the `INACTIVE` status filter
  • Access drafts that are still in progress with the `DRAFT` status filter

Reference Usage

Here is a collection of common scenarios for the Sourcing Profile GraphQL API usage:

Create or Update Sourcing Profile

Author:

Kirill Gaiduk

Changed on:

2 Oct 2025

Overview

The `createSourcingProfile` mutation creates a Sourcing Profile (or its newer version, i.e., updates) for a Retailer:

  • If the provided `ref` is unique, it creates the first version with `ACTIVE` status
  • If a `SourcingProfile` with the same `ref` already exists, it creates a new version with `DRAFT` status

Key points

  • Prerequisites: User should have `SOURCINGPROFILE_CREATE` and `SOURCINGPROFILE_VIEW` permissions
  • Retailer association is permanent: After a Retailer is assigned to a Profile, reassignment to another Retailer is not possible
  • Use clear refs and names: Follow recommended formats (e.g., `GLOBAL_DEFAULT`)
  • Order defines priority: The order of Sourcing Strategies and Criteria determines their application

Inputs

The Input fields for creating a Sourcing Profile are defined with the `CreateSourcingProfileInput`:

Field

Type

Description

Notes

`ref`

`String!`

Unique reference of the Sourcing Profile

Provide a business-readable reference (in order to make the `ref` value more self-descriptive) or an universally unique identifier (UUID)

Recommended format: `<SCOPE>_<SLUG>`
Example: `GLOBAL_DEFAULT`

Parts:

  • SCOPE - where the profile applies: GLOBAL, HQ, market/region codes (ANZ, US, EU), or site codes (SYD, CHI01)
  • SLUG - short purpose label. Use uppercase letters, digits, and underscores only. Examples:
    • Operational defaults: DEFAULT, STANDARD, LOW_SPLIT
    • Speed & promise: FAST, EXPRESS, ECONOMY
    • Product/campaign: SHOES_SUMMER, BACK_TO_SCHOOL, BLACK_FRIDAY
    • Business rules: COST_OPTIMIZED, MARGIN_OPTIMIZED, DISTANCE_OPTIMIZED
    • Special flows: RETURNS_ONLY, PREORDER, VIP

The uniqueness of a Sourcing Profile is determined by the combination of `ref` and `version`

`versionComment`

`String`

Comment for the Sourcing Profile version


`name`

`String!`

Human-readable name of the Sourcing Profile


`description`

`String`

Human-readable description of the Sourcing Profile


`retailer`

`RetailerId!`

Retailer to which the Sourcing Profile belongs to

The Sourcing Profile’s Retailer is immutable after it is set by the create mutation; updates are not allowed

See the Access Validation section below for more details

`defaultVirtualCatalogue`

`VirtualCatalogueKey`

Virtual Catalog Reference used by default

The Virtual Catalog Reference is required to retrieve Available-to-Sell (ATS) quantities for the requested Items

`defaultNetwork`

`NetworkKey`

Network Reference used by default

The Network Reference is required to retrieve the list of available Locations for sourcing request fulfillment

`defaultMaxSplit`

`Int`

Limit of split operations used by default

`Max Split = (allowed number of Fulfillments)  - 1`

  • An empty (`null`) input is treated as zero (In this case, the sourcing request can be fulfilled by only one Fulfillment)
  • Negative inputs are invalid

`sourcingStrategies`

`[CreateSourcingStrategyInput!]`

List of Primary Sourcing Strategies of the Sourcing Profile

The order of inputs defines the `priority` of the Primary Sourcing Strategies

`sourcingFallbackStrategies`

`[CreateSourcingFallbackStrategyInput!]`

List of Fallback Sourcing Strategies of the Sourcing Profile

The order of inputs defines the `priority` of the Fallback Sourcing Strategies

The Input fields for adding Primary and Fallback Sourcing Strategies are defined with the `CreateSourcingStrategyInput` and `CreateSourcingFallbackStrategyInput`:

Field

Type

Description

Notes

`ref`

`String!`

Reference of the Primary / Fallback Sourcing Strategy

The Sourcing Strategy Reference must be unique within a specific Sourcing Profile version

  • When adding a new Sourcing Strategy, provide a new unique `ref`
  • When editing an existing Sourcing Strategy, preserve the same `ref`

Recommendation: use a UUID in order to guarantee uniqueness.

Example: `9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d`

`name`

`String!`

Human-readable name of the Primary / Fallback Sourcing Strategy


`description`

`String`

Human-readable description of the Primary / Fallback Sourcing Strategy


`status`

`String`

Status of the Primary / Fallback Sourcing Strategy

The `status` is `ACTIVE` by default

`virtualCatalogue`

`VirtualCatalogueKey`

Virtual Catalog Reference used by the Primary / Fallback Sourcing Strategy

  • If a Strategy Virtual Catalog is provided, it overrides the `defaultVirtualCatalogue` value
  • If empty (`null`), the Strategy inherits the `defaultVirtualCatalogue` value

`network`

`NetworkKey`

Network Reference used by the Primary / Fallback Sourcing Strategy

  • If a Strategy Network is provided, it overrides the `defaultNetwork` value
  • If empty (`null`), the Strategy inherits the `defaultNetwork` value

`maxSplit`

`Int`

Limit of split operations used by the Primary / Fallback Sourcing Strategy

`Max Split = (allowed number of Fulfillments)  - 1`

  • If a Strategy Max Split is provided, it overrides the `defaultMaxSplit` value
  • If empty (`null`), the Strategy inherits the `defaultMaxSplit` value

Negative inputs are invalid

`sourcingConditions`

`[CreateSourcingConditionInput!]`

List of Sourcing Conditions that determine whether a Sourcing Strategy is applicable to a sourcing request

When multiple Sourcing Conditions are provided, they are evaluated using a logical AND

`sourcingCriteria`

`[CreateSourcingCriterionInput!]`

List of Sourcing Criteria used to rank Locations during the sourcing process

The order of inputs matters because each subsequent Sourcing Criterion acts as a tie-breaker

The Input fields for adding Sourcing Conditions and Criteria are defined with the `CreateSourcingConditionInput` and `CreateSourcingCriterionInput`:

Field

Type

Description

Notes

`name`

`String!`

Name of the Sourcing Condition / Criterion

The Name serves as a unique identifier for Sourcing Conditions and Criteria

`type`

`String!`

Type of the Sourcing Condition / Criterion

The Type is mapped to a specific function in the `util-sourcing` library

`params`

`Json`

Parameters of the Sourcing Condition / Criterion

The Parameters configure Sourcing Conditions and Criteria to support specific customer sourcing logic

Access Validation

The GraphQL framework applies the Standard Permission Check for the target operation and entity:

  • Retailer scope: The Retailer associated with the target entity (or provided in the request) defines the scope for evaluation
  • Role-based access: A user can hold one or more user roles. Each `UserRole` contributes:
    • Permissions via its assigned role (e.g., `SOURCINGPROFILE_CREATE`, `SOURCINGPROFILE_UPDATE`, `SOURCINGPROFILE_VIEW`)
    • Contexts (`RoleContext`) that scope those permissions:
      • `ACCOUNT` - applies across all Retailers
      • `RETAILER` - applies only when the context’s Retailer ID (`contextId`) matches the target Retailer

Result: The request succeeds only if at least one user role grants the required permission in a context applicable to the target Retailer; otherwise, the request is denied or the response contains `null`.

Sample Payload

1mutation createSourcingProfile($input: CreateSourcingProfileInput) {
2    createSourcingProfile (input: $input) {
3        id
4        ref
5        version
6        versionComment
7        name
8        description
9        status
10        user {
11            id
12        }
13        createdOn
14        updatedOn
15        retailer {
16            id
17        }
18        defaultVirtualCatalogue {
19            ref
20        }
21        defaultNetwork {
22            ref
23        }
24        defaultMaxSplit
25        sourcingStrategies {
26            id
27            ref
28            sourcingProfile {
29                id
30            }
31            name
32            description
33            status
34            priority
35            createdOn
36            updatedOn
37            virtualCatalogue {
38                ref
39            }
40            network {
41                ref
42            }
43            maxSplit
44            sourcingConditions {
45                name
46                type
47                params
48            }
49            sourcingCriteria {
50                name
51                type
52                params
53            }
54        }
55        sourcingFallbackStrategies {
56            id
57            ref
58            sourcingProfile {
59                id
60            }
61            name
62            description
63            status
64            priority
65            createdOn
66            updatedOn
67            virtualCatalogue {
68                ref
69            }
70            network {
71                ref
72            }
73            maxSplit
74            sourcingConditions {
75                name
76                type
77                params
78            }
79            sourcingCriteria {
80                name
81                type
82                params
83            }
84        }
85    }
86}
1{
2  "input": {
3    "ref": "GLOBAL_DEFAULT",
4    "versionComment": "Lorem ipsum",
5    "name": "Lorem ipsum",
6    "description": "Lorem ipsum",
7    "retailer": {
8      "id": 1
9    },
10    "defaultVirtualCatalogue": {
11      "ref": "BASE:1"
12    },
13    "defaultNetwork": {
14      "ref": "CLICK_AND_COLLECT"
15    },
16    "defaultMaxSplit": 5,
17    "sourcingStrategies": [
18      {
19        "ref": "bbc42abb-609b-495a-ab74-d3c6d55ca445",
20        "name": "Primary Lorem ipsum",
21        "description": "Primary Lorem ipsum",
22        "status": "ACTIVE",
23        "sourcingConditions": [
24        ],
25        "sourcingCriteria": [          
26          {
27            "name": "locationDistance",
28            "type": "fc.sourcing.criterion.locationDistance"
29          }
30        ]
31      }
32    ],
33    "sourcingFallbackStrategies": [
34      {
35        "ref": "7c194aef-dd50-4d8e-9b8d-b59df4090740",
36        "name": "Fallback Lorem ipsum",
37        "description": "Fallback Lorem ipsum",
38        "status": "ACTIVE",
39        "sourcingConditions": [
40        ],
41        "sourcingCriteria": [          
42          {
43            "name": "locationDistance",
44            "type": "fc.sourcing.criterion.locationDistance"
45          }
46        ]
47      }
48    ]
49  }
50}
1{
2    "data": {
3        "createSourcingProfile": {
4            "id": "607",
5            "ref": "GLOBAL_DEFAULT",
6            "version": 1,
7            "versionComment": "Lorem ipsum",
8            "name": "Lorem ipsum",
9            "description": "Lorem ipsum",
10            "status": "ACTIVE",
11            "user": {
12                "id": "1982"
13            },
14            "createdOn": "2025-08-27T20:33:01.469Z",
15            "updatedOn": "2025-08-27T20:33:01.469Z",
16            "retailer": {
17                "id": "1"
18            },
19            "defaultVirtualCatalogue": {
20                "ref": "BASE:1"
21            },
22            "defaultNetwork": {
23                "ref": "CLICK_AND_COLLECT"
24            },
25            "defaultMaxSplit": 5,
26            "sourcingStrategies": [
27                {
28                    "id": "1019",
29                    "ref": "bbc42abb-609b-495a-ab74-d3c6d55ca445",
30                    "sourcingProfile": {
31                        "id": "607"
32                    },
33                    "name": "Primary Lorem ipsum",
34                    "description": "Primary Lorem ipsum",
35                    "status": "ACTIVE",
36                    "priority": 1,
37                    "createdOn": "2025-08-27T20:33:01.478Z",
38                    "updatedOn": "2025-08-27T20:33:01.478Z",
39                    "virtualCatalogue": null,
40                    "network": null,
41                    "maxSplit": null,
42                    "sourcingConditions": null,
43                    "sourcingCriteria": [
44                        {
45                            "name": "locationDistance",
46                            "type": "fc.sourcing.criterion.locationDistance",
47                            "params": null
48                        }
49                    ]
50                }
51            ],
52            "sourcingFallbackStrategies": [
53                {
54                    "id": "555",
55                    "ref": "7c194aef-dd50-4d8e-9b8d-b59df4090740",
56                    "sourcingProfile": {
57                        "id": "607"
58                    },
59                    "name": "Fallback Lorem ipsum",
60                    "description": "Fallback Lorem ipsum",
61                    "status": "ACTIVE",
62                    "priority": 1,
63                    "createdOn": "2025-08-27T20:33:01.473Z",
64                    "updatedOn": "2025-08-27T20:33:01.473Z",
65                    "virtualCatalogue": null,
66                    "network": null,
67                    "maxSplit": null,
68                    "sourcingConditions": null,
69                    "sourcingCriteria": [
70                        {
71                            "name": "locationDistance",
72                            "type": "fc.sourcing.criterion.locationDistance",
73                            "params": null
74                        }
75                    ]
76                }
77            ]
78        }
79    }
80}

Activate Sourcing Profile

Author:

Kirill Gaiduk

Changed on:

2 Oct 2025

Overview

The `activateSourcingProfile` mutation activates a specific version of a Sourcing Profile. When called, it performs the following actions:

  • Sets the specified version status to `ACTIVE`
  • Updates the previously `ACTIVE` version to `INACTIVE`

Key points

  • Prerequisites: User should have `SOURCINGPROFILE_UPDATE` and `SOURCINGPROFILE_VIEW` permissions
  • Version Control: Activating a new version automatically deactivates the previously `ACTIVE` version, ensuring that only one Sourcing Profile version remains active at any time

Inputs

The Input fields for activating a Sourcing Profile are defined with the `ActivateSourcingProfileInput`:

Field

Type

Description

`ref`

`String!`

Reference of the Sourcing Profile to activate

`version`

`Int!`

Version number of the Sourcing Profile to activate

Access Validation

The GraphQL framework applies the Standard Permission Check for the target operation and entity:

  • Retailer scope: The Retailer associated with the target entity (or provided in the request) defines the scope for evaluation
  • Role-based access: A user can hold one or more user roles. Each `UserRole` contributes:
    • Permissions via its assigned role (e.g., `SOURCINGPROFILE_CREATE`, `SOURCINGPROFILE_UPDATE`, `SOURCINGPROFILE_VIEW`)
    • Contexts (`RoleContext`) that scope those permissions:
      • `ACCOUNT` - applies across all Retailers
      • `RETAILER` - applies only when the context’s Retailer ID (`contextId`) matches the target Retailer

Result: The request succeeds only if at least one user role grants the required permission in a context applicable to the target Retailer; otherwise, the request is denied or the response contains `null`.

Sample Payload

1mutation activateSourcingProfile($input: ActivateSourcingProfileInput) {
2    activateSourcingProfile(input: $input) {
3        ref
4        version
5        status
6    }
7}
1{
2    "input": {
3        "ref": "GLOBAL_DEFAULT",
4        "version": 2
5    }
6}
1{
2    "data": {
3        "activateSourcingProfile": {
4            "ref": "GLOBAL_DEFAULT",
5            "version": 2,
6            "status": "ACTIVE"
7        }
8    }
9}

Get Sourcing Profile

Author:

Kirill Gaiduk

Changed on:

2 Oct 2025

Overview

The `sourcingProfile` query retrieves a Sourcing Profile by its Reference:

  • If a version is provided, the query returns that specific version
  • If no version is provided, the query returns the latest available version

Key points

  • Prerequisites: User should have `SOURCINGPROFILE_VIEW` permission
  • Version Handling: If a version is provided, that exact version is returned. If no version is specified, the query automatically retrieves the latest available version, regardless of status
  • Status Filter: An optional `status` argument lets you filter results (e.g., `ACTIVE`, `INACTIVE`, `DRAFT`) so you can target Profiles in a specific lifecycle state

Inputs

The Input arguments for retrieving a single Sourcing Profile:

Field

Type

Description

Notes

`ref`

`String!`

Reference of the Sourcing Profile


`version`

`Int`

Version number of the Sourcing Profile


`status`

`String`

Status filter

For example:

  • `ACTIVE`
  • `INACTIVE`
  • `DRAFT`

Access Validation

The GraphQL framework applies the Standard Permission Check for the target operation and entity:

  • Retailer scope: The Retailer associated with the target entity (or provided in the request) defines the scope for evaluation
  • Role-based access: A user can hold one or more user roles. Each `UserRole` contributes:
    • Permissions via its assigned role (e.g., `SOURCINGPROFILE_CREATE`, `SOURCINGPROFILE_UPDATE`, `SOURCINGPROFILE_VIEW`)
    • Contexts (`RoleContext`) that scope those permissions:
      • `ACCOUNT` - applies across all Retailers
      • `RETAILER` - applies only when the context’s Retailer ID (`contextId`) matches the target Retailer

Result: The request succeeds only if at least one user role grants the required permission in a context applicable to the target Retailer; otherwise, the request is denied or the response contains `null`.

Sample Payload

1query sourcingProfile($ref: String!, $version: Int, $status: String) {
2    sourcingProfile(ref: $ref, version: $version, status: $status) {
3        id
4        ref
5        version
6        versionComment
7        name
8        description
9        status
10        user {
11            id
12        }
13        createdOn
14        updatedOn
15        retailer {
16            id
17        }
18        defaultVirtualCatalogue {
19            ref
20        }
21        defaultNetwork {
22            ref
23        }
24        defaultMaxSplit
25        sourcingStrategies {
26            id
27            ref
28            sourcingProfile {
29                id
30            }
31            name
32            description
33            status
34            priority
35            createdOn
36            updatedOn
37            virtualCatalogue {
38                ref
39            }
40            network {
41                ref
42            }
43            maxSplit
44            sourcingConditions {
45                name
46                type
47                params
48            }
49            sourcingCriteria {
50                name
51                type
52                params
53            }
54        }
55        sourcingFallbackStrategies {
56            id
57            ref
58            sourcingProfile {
59                id
60            }
61            name
62            description
63            status
64            priority
65            createdOn
66            updatedOn
67            virtualCatalogue {
68                ref
69            }
70            network {
71                ref
72            }
73            maxSplit
74            sourcingConditions {
75                name
76                type
77                params
78            }
79            sourcingCriteria {
80                name
81                type
82                params
83            }
84        }
85    }
86}
1{
2    "ref": "GLOBAL_DEFAULT",
3    "version": 1,
4    "status": "INACTIVE"    
5}
1{
2    "data": {
3        "sourcingProfile": {
4            "id": "1128",
5            "ref": "GLOBAL_DEFAULT",
6            "version": 1,
7            "versionComment": "Lorem ipsum",
8            "name": "Lorem ipsum",
9            "description": "Lorem ipsum",
10            "status": "INACTIVE",
11            "user": {
12                "id": "1982"
13            },
14            "createdOn": "2025-09-01T10:18:24.113Z",
15            "updatedOn": "2025-09-01T10:21:49.386Z",
16            "retailer": {
17                "id": "1"
18            },
19            "defaultVirtualCatalogue": {
20                "ref": "BASE:1"
21            },
22            "defaultNetwork": {
23                "ref": "CLICK_AND_COLLECT"
24            },
25            "defaultMaxSplit": 5,
26            "sourcingStrategies": [
27                {
28                    "id": "2308",
29                    "ref": "bbc42abb-609b-495a-ab74-d3c6d55ca445",
30                    "sourcingProfile": {
31                        "id": "1128"
32                    },
33                    "name": "Primary Lorem ipsum",
34                    "description": "Primary Lorem ipsum",
35                    "status": "ACTIVE",
36                    "priority": 1,
37                    "createdOn": "2025-09-01T10:18:24.118Z",
38                    "updatedOn": "2025-09-01T10:18:24.118Z",
39                    "virtualCatalogue": null,
40                    "network": null,
41                    "maxSplit": null,
42                    "sourcingConditions": null,
43                    "sourcingCriteria": [
44                        {
45                            "name": "locationDistance",
46                            "type": "fc.sourcing.criterion.locationDistance",
47                            "params": null
48                        }
49                    ]
50                }
51            ],
52            "sourcingFallbackStrategies": [
53                {
54                    "id": "1128",
55                    "ref": "7c194aef-dd50-4d8e-9b8d-b59df4090740",
56                    "sourcingProfile": {
57                        "id": "1128"
58                    },
59                    "name": "Fallback Lorem ipsum",
60                    "description": "Fallback Lorem ipsum",
61                    "status": "ACTIVE",
62                    "priority": 1,
63                    "createdOn": "2025-09-01T10:18:24.115Z",
64                    "updatedOn": "2025-09-01T10:18:24.115Z",
65                    "virtualCatalogue": null,
66                    "network": null,
67                    "maxSplit": null,
68                    "sourcingConditions": null,
69                    "sourcingCriteria": [
70                        {
71                            "name": "locationDistance",
72                            "type": "fc.sourcing.criterion.locationDistance",
73                            "params": null
74                        }
75                    ]
76                }
77            ]
78        }
79    }
80}

Search Sourcing Profiles

Author:

Kirill Gaiduk

Changed on:

2 Oct 2025

Overview

The `sourcingProfiles` query retrieves existing Sourcing Profiles. 

It supports multiple filters and pagination.

Key points

  • Prerequisites: User should have `SOURCINGPROFILE_VIEW` permission
  • Flexible Filtering: Multiple filters are supported, including `ref`, `version`, `versionComment`, `name`, `description`, `status`, `defaultMaxSplit`, and date ranges (`createdOn`, `updatedOn`). This lets you target specific Profiles or narrow results down by lifecycle state and time window
  • Pagination Support: The query supports cursor-based pagination (`first`, `last`, `before`, `after`), making it efficient to handle large sets of Sourcing Profiles 

Inputs

The Input arguments for retrieving Sourcing Profiles (i.e., filters):

Field

Type

Description

Notes

`ref`

`[String!]`

Reference of the Sourcing Profile


`version`

`[Int]`

Version number of the Sourcing Profile


`versionComment`

`[String]`

Comment for the Sourcing Profile version


`name`

`[String]`

Human-readable name of the Sourcing Profile


`description`

`[String]`

Human-readable description of the Sourcing Profile


`status`

`[String]`

Status of the Sourcing Profile

For example:

  • `ACTIVE`
  • `INACTIVE`
  • `DRAFT`

`createdOn`

`DateRange`

Filter by creation date

Specify range with `from` and `to`

`updatedOn`

`DateRange`

Filter by last updated date

Specify range with `from` and `to`

`defaultMaxSplit`

`[Int]`

Limit of split operations used by default


`first`

`Int`

Return the first n results


`last`

`Int`

Return the last n results


`before`

`String`

Return results before the specified global ID

This is a cursor (the value is used for pagination)

`after`

`String`

Return results after the specified global ID

This is a cursor (the value is used for pagination)

Access Validation

The GraphQL framework applies the Standard Permission Check for the target operation and entity:

  • Retailer scope: The Retailer associated with the target entity (or provided in the request) defines the scope for evaluation
  • Role-based access: A user can hold one or more user roles. Each `UserRole` contributes:
    • Permissions via its assigned role (e.g., `SOURCINGPROFILE_CREATE`, `SOURCINGPROFILE_UPDATE`, `SOURCINGPROFILE_VIEW`)
    • Contexts (`RoleContext`) that scope those permissions:
      • `ACCOUNT` - applies across all Retailers
      • `RETAILER` - applies only when the context’s Retailer ID (`contextId`) matches the target Retailer

Result: The request succeeds only if at least one user role grants the required permission in a context applicable to the target Retailer; otherwise, the request is denied or the response contains `null`.

Sample Payload

1query sourcingProfiles($ref: [String!]){
2 sourcingProfiles(ref: $ref) {
3    edges {
4        node {
5            id
6            ref
7            version
8            versionComment
9            name
10            description
11            status
12            user {
13                id
14            }
15            createdOn
16            updatedOn
17            retailer {
18                id
19            }
20            defaultVirtualCatalogue {
21                ref
22            }
23            defaultNetwork {
24                ref
25            }
26            defaultMaxSplit
27            sourcingStrategies {
28                id
29                ref
30                sourcingProfile {
31                    id
32                }
33                name
34                description
35                status
36                priority
37                createdOn
38                updatedOn
39                virtualCatalogue {
40                    ref
41                }
42                network {
43                    ref
44                }
45                maxSplit
46                sourcingConditions {
47                    name
48                    type
49                    params
50                }
51                sourcingCriteria {
52                    name
53                    type
54                    params
55                }
56            }
57            sourcingFallbackStrategies {
58                id
59                ref
60                sourcingProfile {
61                    id
62                }
63                name
64                description
65                status
66                priority
67                createdOn
68                updatedOn
69                virtualCatalogue {
70                    ref
71                }
72                network {
73                    ref
74                }
75                maxSplit
76                sourcingConditions {
77                    name
78                    type
79                    params
80                }
81                sourcingCriteria {
82                    name
83                    type
84                    params
85                }
86            }
87        }
88    }
89 }
90}
1{
2    "ref": ["GLOBAL_DEFAULT"]   
3}
1{
2    "data": {
3        "sourcingProfiles": {
4            "edges": [
5                {
6                    "node": {
7                        "id": "1129",
8                        "ref": "GLOBAL_DEFAULT",
9                        "version": 2,
10                        "versionComment": "Lorem ipsum",
11                        "name": "UPDATED Lorem ipsum",
12                        "description": "Lorem ipsum",
13                        "status": "ACTIVE",
14                        "user": {
15                            "id": "1982"
16                        },
17                        "createdOn": "2025-09-01T10:19:08.618Z",
18                        "updatedOn": "2025-09-01T12:51:19.370Z",
19                        "retailer": {
20                            "id": "1"
21                        },
22                        "defaultVirtualCatalogue": {
23                            "ref": "BASE:1"
24                        },
25                        "defaultNetwork": {
26                            "ref": "CLICK_AND_COLLECT"
27                        },
28                        "defaultMaxSplit": 5,
29                        "sourcingStrategies": [
30                            {
31                                "id": "2309",
32                                "ref": "bbc42abb-609b-495a-ab74-d3c6d55ca445",
33                                "sourcingProfile": {
34                                    "id": "1129"
35                                },
36                                "name": "Primary Lorem ipsum",
37                                "description": "Primary Lorem ipsum",
38                                "status": "ACTIVE",
39                                "priority": 1,
40                                "createdOn": "2025-09-01T10:19:08.621Z",
41                                "updatedOn": "2025-09-01T10:19:08.621Z",
42                                "virtualCatalogue": null,
43                                "network": null,
44                                "maxSplit": null,
45                                "sourcingConditions": null,
46                                "sourcingCriteria": [
47                                    {
48                                        "name": "locationDistance",
49                                        "type": "fc.sourcing.criterion.locationDistance",
50                                        "params": null
51                                    }
52                                ]
53                            }
54                        ],
55                        "sourcingFallbackStrategies": [
56                            {
57                                "id": "1129",
58                                "ref": "7c194aef-dd50-4d8e-9b8d-b59df4090740",
59                                "sourcingProfile": {
60                                    "id": "1129"
61                                },
62                                "name": "Fallback Lorem ipsum",
63                                "description": "Fallback Lorem ipsum",
64                                "status": "ACTIVE",
65                                "priority": 1,
66                                "createdOn": "2025-09-01T10:19:08.620Z",
67                                "updatedOn": "2025-09-01T10:19:08.620Z",
68                                "virtualCatalogue": null,
69                                "network": null,
70                                "maxSplit": null,
71                                "sourcingConditions": null,
72                                "sourcingCriteria": [
73                                    {
74                                        "name": "locationDistance",
75                                        "type": "fc.sourcing.criterion.locationDistance",
76                                        "params": null
77                                    }
78                                ]
79                            }
80                        ]
81                    }
82                },
83                {
84                    "node": {
85                        "id": "1128",
86                        "ref": "GLOBAL_DEFAULT",
87                        "version": 1,
88                        "versionComment": "Lorem ipsum",
89                        "name": "Lorem ipsum",
90                        "description": "Lorem ipsum",
91                        "status": "INACTIVE",
92                        "user": {
93                            "id": "1982"
94                        },
95                        "createdOn": "2025-09-01T10:18:24.113Z",
96                        "updatedOn": "2025-09-01T10:21:49.386Z",
97                        "retailer": {
98                            "id": "1"
99                        },
100                        "defaultVirtualCatalogue": {
101                            "ref": "BASE:1"
102                        },
103                        "defaultNetwork": {
104                            "ref": "CLICK_AND_COLLECT"
105                        },
106                        "defaultMaxSplit": 5,
107                        "sourcingStrategies": [
108                            {
109                                "id": "2308",
110                                "ref": "bbc42abb-609b-495a-ab74-d3c6d55ca445",
111                                "sourcingProfile": {
112                                    "id": "1128"
113                                },
114                                "name": "Primary Lorem ipsum",
115                                "description": "Primary Lorem ipsum",
116                                "status": "ACTIVE",
117                                "priority": 1,
118                                "createdOn": "2025-09-01T10:18:24.118Z",
119                                "updatedOn": "2025-09-01T10:18:24.118Z",
120                                "virtualCatalogue": null,
121                                "network": null,
122                                "maxSplit": null,
123                                "sourcingConditions": null,
124                                "sourcingCriteria": [
125                                    {
126                                        "name": "locationDistance",
127                                        "type": "fc.sourcing.criterion.locationDistance",
128                                        "params": null
129                                    }
130                                ]
131                            }
132                        ],
133                        "sourcingFallbackStrategies": [
134                            {
135                                "id": "1128",
136                                "ref": "7c194aef-dd50-4d8e-9b8d-b59df4090740",
137                                "sourcingProfile": {
138                                    "id": "1128"
139                                },
140                                "name": "Fallback Lorem ipsum",
141                                "description": "Fallback Lorem ipsum",
142                                "status": "ACTIVE",
143                                "priority": 1,
144                                "createdOn": "2025-09-01T10:18:24.115Z",
145                                "updatedOn": "2025-09-01T10:18:24.115Z",
146                                "virtualCatalogue": null,
147                                "network": null,
148                                "maxSplit": null,
149                                "sourcingConditions": null,
150                                "sourcingCriteria": [
151                                    {
152                                        "name": "locationDistance",
153                                        "type": "fc.sourcing.criterion.locationDistance",
154                                        "params": null
155                                    }
156                                ]
157                            }
158                        ]
159                    }
160                }
161            ]
162        }
163    }
164}