insert into credential (
       credential_public_id
       , identity_id
       , partial_key
       , type
       , data
       , created_at
       , revoked_at
       , deleted_at
) values (
       $1
       , (select identity_id from identity where identity_public_id = $2)
       , $3
       , $4
       , $5
       , $6
       , $7
       , $8
);
