When importing a record by posting to copycat/imports (mod-copycat), there are three categories of response:
- 200 OK with an internalIdentifier in the response
- 200 OK without an internalIdentifier
- Any other HTTP code.
The meanings of these responses are:
- New record successfully important, and its UUID is known.
- New record queued for import, but its UUID was not known by the time mod-copycat returned its response. (This means it has polled several times for the new record, but not seen it.)
- Some kind of hard error, such as misconfiguration of the Z39.50 target details.
We want the UI to handle these responses as follows:
- Show a green toast stating that the record was imported successfully, and redirect to the new record.
- Show a yellow toast stating that the record was queued for import.
- Red toast stating the error.