DEMData record not found using the provided identifiers
Error message (sample)
The server-submit endpoint returns HTTP 400 Bad Request with a response similar to:
{
"responseCode": null,
"message": null,
"content": null,
"numberOfSubQueries": null,
"errors": [
"DEMData record not found using the provided identifiers."
],
"warnings": null,
"concurrencyTokens": null,
"performance": null,
"stackTrace": null,
"errorType": null
}
Symptoms
- A call to
POST /dem/demdata/serversubmit/{customerid}/{environmentid}returns HTTP400. - The service principal has passed authentication and authorization, but the draft is not promoted.
- The response contains
DEMData record not found using the provided identifiers.
Scope
This error applies to the server-submit API on both SaaS and customer-hosted installations.
Root cause
The API could not find a DEMData record in the customer and environment specified in the request URL using the lookup strategy in the request body.
Server-submit supports exactly one of these lookup strategies:
| Strategy | Matching fields |
|---|---|
| Direct record lookup | demdataId must match the DEMData record ID. |
| Form and reference lookup | formId must match the record's DEM Render ID and referenceNumber must match its reference number. Both values are required. |
| Root-record lookup | rootRecordPrimaryKey must match the primary target record ID associated with the draft. |
Possible causes and checks
| Possible cause | How to check |
|---|---|
| The URL names a different customer or environment from the one where the draft was created. | Compare {customerid} and {environmentid} with the draft's environment. Check for test and production values being mixed. |
demdataId is mistyped, stale, or is another type of ID. |
Compare it with the DEMData ID returned when that draft was created or saved. A form ID, reference number, or target record ID cannot be used as demdataId. |
formId is not the draft's DEM Render ID, or referenceNumber is incorrect. |
Check both values against the same saved draft. A form display name or target record ID is not a formId. |
formId and referenceNumber each look valid but identify different drafts. |
Check that both were captured from the same draft and environment. |
| The draft no longer exists, for example because it was deleted or expired. | Find the draft in the selected environment. If it is gone, create or save a new draft and use its new demdataId. |
rootRecordPrimaryKey is incorrect, or the draft does not yet have a primary target record ID. |
Compare the value with the primary target record ID associated with that draft. If none has been created yet, use demdataId instead. |
| An indirect lookup cannot find an older draft in an environment with many records. | Retry with demdataId. Current form/reference and root-record lookups page through the scoped partition with a bounded execution budget; use direct demdataId to avoid scan timeouts. Older versions searched at most 1,000 records. |
| An identifier has leading or trailing spaces, or a GUID is represented differently from the stored value. | Copy the identifier from the original draft or response and compare the full value, including punctuation. Letter case alone does not affect matching. |
Resolution
- Confirm that
{customerid}and{environmentid}in the endpoint URL identify the environment where the draft was created. Do not send a development or test identifier to a production environment, or the reverse. - Send exactly one lookup strategy in the JSON body.
submittedByUserIdis audit information and is not used to locate the record. -
Where possible, use the DEMData ID returned when the draft is created or saved:
-
If using
formIdandreferenceNumber, verify both values against the same saved draft. The form ID must be the DEM Render ID, not a form display name or target record ID. - If using
rootRecordPrimaryKey, verify that the draft already has a primary target record ID and that the supplied value matches it. - Confirm that the draft still exists in the selected environment. If it has been deleted or expired, create or save a new draft and submit using its new
demdataId. - If an indirect lookup still fails, retry with
demdataId. If you cannot obtain it, contact ProcessFactorial support with the customer ID, environment ID, lookup values, request time, and master correlation ID. Do not include access tokens or secrets.
Notes and references
- Server-Submit (Draft Promotion via Service Principal)
- An invalid combination of lookup strategies produces a different validation error, such as
Only one lookup strategy may be provided at a time. - Authentication, authorization, and a draft that is found but cannot be submitted produce different errors.
Shared lookup with Server-Delete
Current submit and Server-Delete use one lookup resolver. Missing/partial/mixed selectors are invalid and multiple matches are a conflict. Search budget exhaustion or a query failure is an error rather than not-found. Server-Delete uses HTTP 404 for an absent draft; submit retains its existing error mapping. An absent draft is unavailable to submit/resume, but this API adds no permanent deletion marker or protection against a stale concurrent save. Retry deletion using the immutable demdataId, because indirect identifiers can later match a different draft.