Skip to main content

Codes

Get code information

GET /codes/:id

Get the code information by code ID.

Endpoint URL

 https://api.mixin.one/codes/:id

Authentication and options

Authorization
Public
LimitationNo limitation

Example request

curl -i -X GET -H "Content-Type: application/json"  https://api.mixin.one/codes/f32a5130-94eb-4f8b-bb46-5b3735c10999

Code types

Type of codeDescription
UserCode ID of a user.
ConversationCode ID of a conversation.
PaymentCode ID of a payment.
Multisig RequestCode ID of a multi-signature request.
CollectibleCode ID of a collectible transaction.
Response (User)
{
"data": {
"type": "user",
"user_id": "44d9717d-8cae-4004-98a1-f9ad544dcfb1",
"identity_number": "25566",
"phone": "",
"full_name": "Name",
"biography": "Bio",
"avatar_url": "https://mixin-images.zeromesh.net/7RKXjQPvFDSiTXVP4EMyEHK2xDPEcgBM0ZlY-ft_8FxWgmFCAhumR9dtX-BYfwAJ5KtfOF1AujmPbyFC6ZX1l2d_ELwynAgu2-0F=s256",
"relationship": "",
"mute_until": "0001-01-01T00:00:00Z",
"created_at": "2017-11-28T08:05:49.959425563Z",
"is_verified": false,
"is_scam": false
}
}
Response (Conversation)
{
"data": {
"type": "conversation",
"conversation_id": "29ac9cb8-2201-44a6-8253-8bfac39ab05f",
"creator_id": "44d9717d-8cae-4004-98a1-f9ad544dcfb1",
"category": "CONTACT" | "GROUP",
"name": "",
"icon_url": "",
"announcement": "",
"created_at": "2021-10-23T05:13:21.080502889Z",
"code_id": "",
"code_url": "",
"mute_until": "2022-06-06T13:58:41.290495483Z",
"expire_in": 0,
"participants": [
{
"type": "participant",
"user_id": "382f37da-b247-4623-8bc8-ce2a12db56bd",
"role": "",
"created_at": "2021-10-23T05:13:21.119482Z"
},
{
"type": "participant",
"user_id": "44d9717d-8cae-4004-98a1-f9ad544dcfb1",
"role": "OWNER",
"created_at": "2021-10-23T05:13:21.119482Z"
},
...
],
"participant_sessions": [
{
"type": "participant",
"user_id": "382f37da-b247-4623-8bc8-ce2a12db56bd",
"session_id": "4b00c9dc-6e8e-4807-a0e9-35d2a345c918",
"public_key": "rTWvPDPFrxXIn0zwQVSyxqgDy21HOTInVf0m3XS_AAQ"
},
{
"type": "participant",
"user_id": "44d9717d-8cae-4004-98a1-f9ad544dcfb1",
"session_id": "20f6a174-e370-424b-a25d-b64c6eb4dbf2",
"public_key": "4badX8iVovtF_Iw0ausF5gZrdo6jip4KhL3ZX2m4uUc"
},
...
],
"circles": [
{
"type": 'circle',
"circle_id": ,
"user_id": ,
"name": ,
"created_at": ,
},
...
],
}
}
Response (Payment)
{
"data":{
{
"type":"payment",
"trace_id":"7a9aac77-528d-470f-9e6a-ce6ff0826b2b",
"asset_id":"965e5c6e-434c-3fa9-b780-c50f43cd955c",
"amount":"0.00000002",
"threshold":3,
"receivers":[
"a15e0b6d-76ed-4443-b83f-ade9eca2681a","b9126674-b07d-49b6-bf4f-48d965b2242b","15141fe4-1cfd-40f8-9819-71e453054639","3e72ca0c-1bab-49ad-aa0a-4d8471d375e7"
],
"memo":"AAGGxYdl7IE8pKNbh181oK19AAAAAAA5AFSFbhSxW7QF4tfjywX2ansSCryLYxRjqwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA",
"created_at":"2022-06-06T12:40:53.857926164Z",
"status":"pending",
"code_id":"9ce76edb-6fc9-4a4e-b01c-567cb7ae0aa2"
}
}
}
Response (Multisig)
{
"data":{
"type": "multisig_request";
"request_id": "29ac9cb8-2201-44a6-8253-8bfac39ab05f",
"user_id": "29ac9cb8-2201-44a6-8253-8bfac39ab05f",
"asset_id": "29ac9cb8-2201-44a6-8253-8bfac39ab05f",
"amount": "0.1",
"threshold": 3,
"senders": [
"a15e0b6d-76ed-4443-b83f-ade9eca2681a","b9126674-b07d-49b6-bf4f-48d965b2242b","15141fe4-1cfd-40f8-9819-71e453054639","3e72ca0c-1bab-49ad-aa0a-4d8471d375e7"
],
"receivers": [
"a15e0b6d-76ed-4443-b83f-ade9eca2681a","b9126674-b07d-49b6-bf4f-48d965b2242b","15141fe4-1cfd-40f8-9819-71e453054639","3e72ca0c-1bab-49ad-aa0a-4d8471d375e7"
],
"signers": [
"15141fe4-1cfd-40f8-9819-71e453054639","3e72ca0c-1bab-49ad-aa0a-4d8471d375e7"
],
"memo": "",
"action": "sign" | "unlock",
"state": "initial" | "signed",
"transaction_hash": "",
"raw_transaction": "",
"created_at": "2022-06-06T12:40:53.857926164Z",
"updated_at": "2022-06-06T12:40:53.857926164Z",
"code_id": "29ac9cb8-2201-44a6-8253-8bfac39ab05f",
}
}
Response (Collectible)
{
"data": {
"type": "non_fungible_request",
"request_id": "29ac9cb8-2201-44a6-8253-8bfac39ab05f",
"user_id": "29ac9cb8-2201-44a6-8253-8bfac39ab05f",
"token_id": "29ac9cb8-2201-44a6-8253-8bfac39ab05f",
"amount": "0.1",
"senders": [
"a15e0b6d-76ed-4443-b83f-ade9eca2681a","b9126674-b07d-49b6-bf4f-48d965b2242b","15141fe4-1cfd-40f8-9819-71e453054639","3e72ca0c-1bab-49ad-aa0a-4d8471d375e7"
],
"senders_threshold": 3,
"receivers": [
"a15e0b6d-76ed-4443-b83f-ade9eca2681a","b9126674-b07d-49b6-bf4f-48d965b2242b","15141fe4-1cfd-40f8-9819-71e453054639","3e72ca0c-1bab-49ad-aa0a-4d8471d375e7"
],
"receivers_threshold": 3,
"signers": [
"15141fe4-1cfd-40f8-9819-71e453054639","3e72ca0c-1bab-49ad-aa0a-4d8471d375e7"
],
"action": "sign",
"state": "initial" | "signed",
"transaction_hash": "",
"raw_transaction": "",
"created_at": "2022-06-06T12:40:53.857926164Z",
"updated_at": "2022-06-06T12:40:53.857926164Z",
"code_id": "29ac9cb8-2201-44a6-8253-8bfac39ab05f",
}
}