Session tokens
Session tokens provide the context with which the requests made by a user can be related to the document they are editing at that time, or the way they got there. In Fonto, the edit
is used to identify this context.
By including an edit
in the scope
initialization parameter, Fonto will be able to pass it back to the CMS when making any API call. This allows the author to be reliably identified and work in Fonto across multiple tabs.
For example, when using locking the edit
can be used to identify two different sessions for the same user allowing a lock to be applied in one of the sessions but not the other.
The edit session token must not be used for authentication. See Authentication for more information.
The session token given to Fonto is never modified by Fonto. Therefore, the edit
can be any identifier that your CMS can relate back to your user's context of work -- such as the browser tab that was opened or a folder that was being browsed at the time of opening Fonto.
Requests made by Fonto
Most requests that Fonto makes will have a context (context
) object in which the edit
given to Fonto initially is echoed back to the CMS.
The context
request object may also contain identifiers for the folder (folder
), document (document
) and/or referrer document (referrer
) each relating to the context in which a request is made.
For example, when a user is browsing for a document to link to, the document identifier of the document in which the link will be created is passed to the CMS so it can scope the browse action.
This article is referenced from...
Guides and concept pages: