mts-booking-library
v3.3.0
Published
Library for using MyTicketSolution Booking API
Readme
Publish
To publish a new version of the library, first create a new version with the npm version command,
specifying the semver increment (patch, minor or major, e.g. npm version patch).
The library will be published to npm by the pipelines every time a new version is detected on the
main branch.
For that to work, the NPM_TOKEN secret must be kept up-to-date, as it expires every 90 days
and has to be rotated manually.
LAST UPDATE: 2026-05-07
How to update the npm token
- Go to https://www.npmjs.com/login
- Login with the
sviluppatoriinfosusername, and its password - 2FA will be required, ask Jacopo Gargano ([email protected])
- Once logged in, navigate to https://www.npmjs.com/settings/sviluppatoriinfos/tokens
- On that page, delete the outdated token
- Click on "Generate New Token" (may require a second 2FA code)
- Use the following settings:
- Token name:
mts-booking-library publishing - Bypass two-factor authentication (2FA): true
- Packages and scopes
- Permissions: Read and write
- Select packages > Only select packages and scopes:
mts-booking-library
- Expiration > Expiration Date: 90 days
- Token name:
- Click on "Generate token", and copy the token
- Go to the edit pipeline page in Azure: https://dev.azure.com/infoservicesrl/MyTicketSolution%202.0/_apps/hub/ms.vss-build-web.ci-designer-hub?pipelineId=88&branch=main
- Click on Variables >
NPM_TOKEN - Paste the new value, then Save > Save
- Update the date above
Test
npm install && npm run test
Linting
npm run lint
Will run ESLint on the project.
npm run lint:quiet
Will run ESLint on the project, but will ignore warnings.
npm run lint:fix
Will run ESLint on the project, fixing the errors that can be fixed automatically.
