Odoo Community
Odoo Enterprise
Viindoo Cloud
Share links that stop working when you said they would
Access tokens with an expiry date and an automatic rotation - so a link that was shared once does not stay valid forever.
Token Expiration (technical name to_token_expiration) is an Odoo 17.0 app for Odoo Community and Odoo Enterprise and Viindoo Cloud, built for whoever shares, security or compliance, administrator, developer.
At a Glance
The facts of Token Expiration, version 0.1, in one place. Published by Viindoo.
Technical name
to_token_expiration
Odoo version
17.0 (Odoo Community, Odoo Enterprise, Viindoo Cloud)
Depends on
resource, base_setup
Adds
2 new models, 2 extended models, 1 menu, 1 scheduled action, 1 setting, 1 access group
Best for
Whoever shares; Security or compliance; Administrator; Developer
Not for
It does not expire portal logins.
Key features
An access token as a record, with an expiry date, A company-wide lifetime in days - zero means never expire, A scheduled job that rotates expired tokens in batches, The old URL stops resolving the moment the token rotates, A mixin any model can inherit to get expiring links, Tokens are tied to their record, and are refused a copy
How It Works
Two screens - and then a scheduled job does the work.
1
Every live token, with its expiry
The record each token belongs to and the moment it stops working. Expired ones are rotated by the scheduler and disappear from here.
2
On the record that was shared
The share carries the token; when it rotates, the link people were given stops opening the document.
What You Get
An access token as a record, with an expiry date
A company-wide lifetime in days - zero means never expire
A scheduled job that rotates expired tokens in batches
The old URL stops resolving the moment the token rotates
A mixin any model can inherit to get expiring links
Tokens are tied to their record, and are refused a copy
More Screens
Everything below was taken on a database seeded with real business data, on this series - not a mock-up and not a screenshot from an older version.
What This App Does Not Do
Read this before you buy. Everything below is something the app deliberately leaves to another app or to you.
It does not expire portal logins.
This is about token links, not about sessions or user accounts.
One lifetime per company.
There is no per-record expiry to set by hand - the lifetime is a policy, applied uniformly.
Rotation happens on a schedule.
A token expires at its date and is rotated by the next run of the job, not to the second.
Only models that use the mixin are covered.
Viindoo apps that share links use it; a custom model gets it by inheriting the mixin.
The lifetime setting is developer-visible.
It sits in the general settings behind developer mode, because it is a policy set once, not a daily switch.
Works Well With
Apps from the same stack, built to fit this one:
Document Management
The share links this puts a clock on.
viin_document
Odoo Module Catalogue
Download links that should not live forever.
to_odoo_module
Who Should Use Token Expiration?
Whoever shares
Sends a link that stops being valid on a date instead of forever.
Security or compliance
Has an answer to "who can still open that document".
Administrator
Sets one number, in days, per company.
Developer
Inherits a mixin instead of writing token rotation again.
Frequently Asked Questions
What does Token Expiration do?
Access tokens with an expiry date and an automatic rotation - so a link that was shared once does not stay valid forever.
What does Token Expiration not do?
It does not expire portal logins. This is about token links, not about sessions or user accounts. One lifetime per company. There is no per-record expiry to set by hand - the lifetime is a policy, applied uniformly. Rotation happens on a schedule. A token expires at its date and is rotated by the next run of the job, not to the second. Only models that use the mixin are covered. Viindoo apps that share links use it; a custom model gets it by inheriting the mixin. The lifetime setting is developer-visible. It sits in the general settings behind developer mode, because it is a policy set once, not a daily switch.
Who is Token Expiration for?
Whoever shares: Sends a link that stops being valid on a date instead of forever. Security or compliance: Has an answer to "who can still open that document". Administrator: Sets one number, in days, per company. Developer: Inherits a mixin instead of writing token rotation again.
Which Odoo version and editions does it support?
Odoo 17.0 - Odoo Community, Odoo Enterprise, Viindoo Cloud. Upgrades to a newer Odoo series are a separate purchase for that series.
What does it depend on?
It installs on top of: resource, base_setup. Odoo installs them with it.
How do I set it up?
Two screens - and then a scheduled job does the work.
What works well with it?
Document Management (viin_document): The share links this puts a clock on. Odoo Module Catalogue (to_odoo_module): Download links that should not live forever. Signup Verification (to_signup_email_verification): The other half of tightening portal access.
Can I try it before buying?
Yes - the Live Preview button at the top of this page opens the module's own screen on a working database.
How do I get support?
Write to apps.support@viindoo.com with your Odoo version and the technical name to_token_expiration; pre-sales questions go to sales@viindoo.com.
Need help with Token Expiration?
For questions, implementation support or a custom feature, contact Viindoo.
Upgrades to a newer Odoo series are a separate purchase for that series.
All Viindoo apps: apps.odoo.com/apps/modules/browse?author=Viindoo
About Viindoo. Viindoo builds and maintains more than 1,000 apps on the Odoo App Store for the Community and Enterprise editions and runs them on Viindoo Cloud. A purchase of Token Expiration covers the 17.0 series: bug fixes on the module reach you through the store, questions go to apps.support@viindoo.com with the technical name to_token_expiration, and moving to a newer Odoo series is a separate purchase for that series. Source code is delivered with the module and stays yours to read and adapt.
Technical Requirement
Editions: Odoo Community, Odoo Enterprise, Viindoo Cloud
Changes log
0.1 - Latest on the 17.0 line
- Expired tokens are rotated in batches by a scheduled job, and the job re-triggers itself when more remain.
- Tokens cannot be duplicated, and their model and record cannot be moved.
Installation
- Navigate to Apps.
- Search with keyword to_token_expiration.
- Press Install.
Instructions
Below is an example of how to use this module to manage the URL expiration while sharing documents in the Documents app.
To manage the tokens, you need to activate the developer mode.
Step 1: Navigate to Settings > General Settings, find the Default Token Lifetime feature, and configure the expiration time of the documents sharing URLs, counting by days.
Read more details on how to configure the expiration date for document sharing.
Step 2: Go to the Documents app, select the documents that you want to share, press Share then click Generate URL. An URL to share the selected documents will be generated automatically.
Step 3: Navigate to Settings > Technical > Rotating Tokens to view the token auto-created for the URL generated in step 2.
Step 4: Click on any token, you will see the default Expiry Date of this token is the Default Token Lifetime configured previously. This information can be modified.
Note: After the Expiry Date, other people no longer can view documents from the URL that you have shared with them.
This software and associated files (the "Software") may only be
used
(executed, modified, executed after modifications) if you have
purchased a
valid license from the authors, typically via Odoo Apps,
or if you
have
received a written agreement from the authors of the
Software (see the
COPYRIGHT file).
You may develop Odoo modules that use the Software as a library
(typically
by depending on it, importing it and using its
resources), but
without
copying any source code or material from the
Software. You may distribute
those modules under the license of your
choice, provided that this
license
is compatible with the terms of
the Odoo Proprietary License (For
example:
LGPL, MIT, or proprietary
licenses similar to this one).
It is forbidden to publish, distribute, sublicense, or sell
copies of the
Software or modified copies of the Software.
The above copyright notice and this permission notice must be
included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT
SHALL THE
AUTHORS OR COPYRIGHT HOLDERS
BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN
ACTION OF CONTRACT, TORT OR OTHERWISE,
ARISING
FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE
SOFTWARE.