I would do

replace_with_string (a_value: detachable READABLE_STRING_GENERAL; a_key: JSON_STRING)
 ...

see comment on `put_string'