
Security News
Microsoft Releases Open Source Toolkit for AI Agent Runtime Security
Microsoft has released an open source toolkit for enforcing runtime security policies on AI agents as adoption accelerates faster than governance controls.
@hapify/generator
Advanced tools
This package allows you to generate code using Hapify models and Hapify or JavaScript code templates.
import { Generator } from '@hapify/generator';
const templates = [
{
path: '/path/to/{snake}',
engine: 'hpf',
input: 'one',
content: 'Camel case is <<Model camel>>.',
}
];
const models = [
{
id: 'bdc6c58e-ec49-9193-6b29-6c75518bc3ad',
name: 'Place bookmark',
notes: 'A user can only list its own bookmarks',
fields: [
{
name: '_id',
notes: null,
type: 'string',
subtype: null,
value: null,
primary: true,
unique: false,
label: false,
nullable: false,
multiple: false,
embedded: false,
searchable: false,
sortable: false,
hidden: false,
internal: true,
restricted: false,
ownership: false
}
],
accesses: {
create: 'auth',
read: 'owner',
update: 'admin',
remove: 'owner',
search: 'owner',
count: 'owner'
}
}
];
// Get path & content
Generator.run(templates, models)
.then(results => {
// [{ path: '/path/to/place_bookmark', content: 'Camel case is placeBookmark' }]
});
// Get path only
const path = Generator.path('/path/to/{camel}', models[0]); // '/path/to/placeBookmark'
For more information about this module, please refer to the online documentation.
FAQs
Generator for Hapify templates
The npm package @hapify/generator receives a total of 23 weekly downloads. As such, @hapify/generator popularity was classified as not popular.
We found that @hapify/generator demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Microsoft has released an open source toolkit for enforcing runtime security policies on AI agents as adoption accelerates faster than governance controls.

Security News
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.