API version:
  • 1.0
  • 1.1
  • 2.0

accounts/files/related

Supported methods

GET

GET: List of other files related to a given file

Returns a list of files that are related to the given file. Currently, relation between files is based on how similar their names are.

GET https://api.context.io/2.0/accounts/id/files/file_id/relatedtest it
idUnique id of an account accessible through your API key
file_idUnique id of a file

Response body

[
  {
    "size": numberSize of file in bytes.,
    "type": stringMIME type as specified in message source,
    "subject": stringSubject line of message this file is attached to,
    "date": numberUnix timestamp of the message,
    "date_indexed": numberTime this message was first seen by Context.IO (unix timestamp),
    "addresses": objectEmail addresses and names of sender and recipients (more details),
    "person_info": objectAdditional info about contacts on the message (more details),
    "similarity": numbersimilarity factor of the file's name,
    "file_name": stringName of file,
    "file_name_structure": arrayName of the file broken down in semantic parts (more details),
    "file_id": stringUnique and persistent id for this file,
    "supports_preview": booleanwhether or not the file supports our preview function,
    "is_embedded": booleanIndicates whether this file is an object embedded in the message or not,
    "content_disposition": stringValue of the Content-Disposition header of the MIME part containing this file, if specified. Typically 'inline' or 'attachment',
    "content_id": stringIf this file is an embedded object, this is the value of the Content-Id header of the MIME part containing this file,
    "message_id": stringContext.IO id of the message this file is attached to,
    "email_message_id": stringValue of RFC-822 Message-ID header this file is attached to,
    "gmail_message_id": stringGmail message id the file is attached to (only present if source is a Gmail account),
    "gmail_thread_id": stringGmail thread id the file is attached to (only present if source is a Gmail account)
  },
  ...
]