
Security News
crates.io Ships Security Tab and Tightens Publishing Controls
crates.io adds a Security tab backed by RustSec advisories and narrows trusted publishing paths to reduce common CI publishing risks.
@hiro-ui/sdk
Advanced tools
Initializes the SDK and provides config details from HIRO Desktop. initSdk also provides a ready callback and a state object.
const config = {}; // Optional default config
initSdk(config).then(
({
config: { } // Config values provided by SDK
ready, // Callback, once your application is ready
state, // Stored application state
}: InitSdkResult) => {
// SDK is initialized and ready to use
}
);
Closes the application within HIRO Desktop
close();
Callback to SDK for unauthorized Token
unauthorized();
Sync application state back to HIRO Desktop
const state = {}; // Application state object
saveState(state);
Open a different application, with parameters, from within your application.
const appParameters = {}; // Parameters for the new application
runApp(appId, appParameters);
interface SdkConfig {
authUrl?: string;
graphUrl?: string;
redirectUrl?: string;
clientId?: string;
roles?: string[];
}
interface LoadedConfig {
graphUrl?: string;
token?: string;
}
interface DesktopUser {
_id: string;
accountId: string;
email: string;
id: string;
name: string;
roles: string[];
}
interface DesktopConfig {
user: DesktopUser;
org: {
id: string;
name: string;
};
token: string;
graphUrl: string;
shared: {
[key: string]: any;
};
options?: {
[key: string]: any;
};
}
InitSdkResult TypeScript Interface
interface InitSdkResult<S = {}> {
ready: () => void;
state: S;
config: DesktopConfig;
}
import React from 'react';
import ReactDOM from 'react-dom';
import YourReactApp from './YourReactApp';
import {
SdkConfig, // SdkConfig TypeScript Interface
InitSdkResult, // InitSdkResult TypeScript Interface
initSdk, // Initializes the SDK
unauthorized, // Callback to SDK for unauthorized Token
} from '@hiro-ui/sdk';
import Client, { Token } from '@hiro-graph/client';
// Default config for Development
const config: SdkConfig = {
clientId: process.env.HIRO_CLIENT_ID,
graphUrl: process.env.HIRO_GRAPH_URL,
authUrl: process.env.HIRO_AUTH_URL,
redirectUrl: process.env.HIRO_REDIRECT_URL,
scopeId: process.env.HIRO_SCOPE_ID,
};
// Initializes the SDK with Default config
initSdk(config).then(
({
config: { user, graphUrl, token, shared, scopeId, options },
ready, // Callback, once your application is ready
state, // Stored application state
}: InitSdkResult) => {
// SDK is initialized and ready to use
const myToken = new Token({
onInvalidate: () => {
// Handle unauthorized Token
unauthorized();
return Promise.resolve();
},
getToken: () => Promise.resolve(token),
});
// Get Graph Client with SKD Configs
const graphClient = new Client({
endpoint: graphUrl,
token: myToken,
});
ReactDOM.render(
<YourReactApp />,
document.getElementById('app'),
ready, //ready callback for SDK
);
},
);
FAQs
HIRO Applications SDK.
We found that @hiro-ui/sdk demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer 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
crates.io adds a Security tab backed by RustSec advisories and narrows trusted publishing paths to reduce common CI publishing risks.

Research
/Security News
A Chrome extension claiming to hide Amazon ads was found secretly hijacking affiliate links, replacing creators’ tags with its own without user consent.

Security News
A surge of AI-generated vulnerability reports has pushed open source maintainers to rethink bug bounties and tighten security disclosure processes.