Clear filter
Article
Renan Lourenco · Mar 9, 2020
# InterSystems IRIS for Health ENSDEMO
Yet another basic setup of ENSDEMO content into InterSystems IRIS for Health.
**Make sure you have Docker up and running before starting.**
## Setup
Clone the repository to your desired directory
```bash
git clone https://github.com/OneLastTry/irishealth-ensdemo.git
```
Once the repository is cloned, execute:
**Always make sure you are inside the main directory to execute docker-compose commands.**
```bash
docker-compose build
```
## Run your Container
After building the image you can simply execute below and you be up and running 🚀:
*-d will run the container detached of your command line session*
```bash
docker-compose up -d
```
You can now access the manager portal through http://localhost:9092/csp/sys/%25CSP.Portal.Home.zen
- **Username:** SuperUser
- **Password:** SYS
- **SuperServer port:** 9091
- **Web port:** 9092
- **Namespace:** ENSDEMO

To start a terminal session execute:
```bash
docker exec -it ensdemo iris session iris
```
To start a bash session execute:
```bash
docker exec -it ensdemo /bin/bash
```
Using [InterSystems ObjectScript](https://marketplace.visualstudio.com/items?itemName=daimor.vscode-objectscript) Visual Studio Code extension, you can access the code straight from _vscode_

## Stop your Container
```bash
docker-compose stop
```
## Support to ZPM
```bash
zpm "install irishealth-ensdemo"
```
Nice, Rhenan! And ZPM it, please, too! Interesting.
Is it available for InterSystems IRIS? Will do soon! Haven't tested but I would guess yes, I will run some tests changing the version in Dockerfile and post the outcome here. Hi, here is a similar article about ensdemo for IRIS and IRIS for health.
https://community.intersystems.com/post/install-ensdemo-iris Works for IRIS4Health Also available as ZPM module now:
USER>zpm "install irishealth-ensdemo"[irishealth-ensdemo] Reload START (/usr/irissys/mgr/.modules/USER/irishealth-ensdemo/1.0.0/)[irishealth-ensdemo] Reload SUCCESS[irishealth-ensdemo] Module object refreshed.[irishealth-ensdemo] Validate START[irishealth-ensdemo] Validate SUCCESS[irishealth-ensdemo] Compile START[irishealth-ensdemo] Compile SUCCESS[irishealth-ensdemo] Activate START[irishealth-ensdemo] Configure START[irishealth-ensdemo] Configure SUCCESS[irishealth-ensdemo] MakeDeployed START[irishealth-ensdemo] MakeDeployed SUCCESS[irishealth-ensdemo] Activate SUCCESS
USER>
Here is the set of productions available:
Is there any documentation on what the ens-demo module can do? Unfortunately not as I'd like it to have. Even when ENSDEMO was part of Ensemble information was a bit scattered all over.
If you access the Ensemble documentation and search for "Demo." you can see some of the references I mentioned. (since IRIS does not have ENSDEMO by default, documentation has also been removed) Thanks, @Renan.Lourenco !
Perhaps, we could wrap this part of the documentation as a module too. Could be a nice extension to the app. I like your idea @Evgeny.Shvarov !! How do you envision that, a simple index with easy access like:
DICOM:
Link1
Link2
HL7
Link1
Link2
Or something more elaborated?
Also would that be a separate module altogether or part of the existing? I see that the documentation pages are IRIS CSP classes. So I guess it could work if installed in IRIS. I guess also there is a set of static files (FILECOPY could help).
IMHO, the reasonable approach to have a separate repo ensdemo-doc and a separate module the, which will be a dependent module to irishealth-ensdemo
So people could contribute to documentation independently and update it independently too.
I had my bit of fun with documentation before, they are not as straightforward as they appear to be. That's why I thought of having a separate index. I guess you know more about it.
I’d also ping @Dmitry.Maslennikov as he tried to make a ZPM package for the whole documentation.
Announcement
Anastasia Dyubaylo · Apr 12, 2023
Hey Developers,
Enjoy watching the new video on InterSystems Developers YouTube:
⏯ System Performance Review for InterSystems IRIS Applications @ Global Summit 2022
If you hit a bottleneck in system resources, your users will suffer. So to ensure your systems are the right size, you need to understand how your InterSystems IRIS applications use system resources. This is even more important when you move applications to the cloud, where vendors impose strict limits on capacity and throughput. In this session, you'll learn the key metrics and how to collect them.
🗣 Presenter: @Murray.Oldfield, Principal Technology Architect, InterSystems
Hope you like it and stay tuned! 👍
Announcement
Bob Kuszewski · Nov 22, 2022
Announcing the InterSystems Container Registry web user interface
InterSystems is pleased to announce the release of the InterSystems Container Registry web user interface. This tool is designed to make it easier to discover, access, and use the many Container images hosted on ICR.
The InterSystems Container Registry UI is available at: https://containers.intersystems.com/contents
Community Edition Containers
When you visit the ICR user interface, you’ll have access to InterSystems' publicly available containers, including the IRIS community edition containers. Use the left-hand navigation to select the product family that interests you, then the container, and finally select the specific version.
Enterprise Edition Containers
You can see the private containers, including the IRIS enterprise edition, by clicking on the Login button. Once logged in, the left-hand navigation will include all the containers you have access to.
Enjoy!
That great, can be very useful to just check if a version is still available or the one that just came out. A great resource for our community - thanks! This is nice !! Thank you @Robert.Kuszewski !! SUPER !!!
Announcement
Raj Singh · Jan 10, 2023
We have just released a minor update to the package manager, which has been renamed from ZPM to IPM as I explained in November. It purely a bug fix release, properly interpreting ROBOCOPY return codes and fixing a regression that prevented installation of certain packages.
Get it here:
https://github.com/intersystems/ipm/releases/tag/v0.5.2
Announcement
Olga Zavrazhnova · Jan 12, 2023
Hi Community, Let's meet virtually at our first Community Roundtable in 2023! Join the discussion on best practices for developing in VS Code/Studio, use cases, and Q&A.📅 Date: January 26🕑 Time: 9:00 am ET | 3:00 pm CET
UPDATE: the roundtable recording is available here.
Let us know in advance which questions you'd like us to cover - comment on this post or send your questions to me in DM.Not a member of Global Masters? Join now - log in using InterSystems SSO credentials. Image (here and on Global Masters) incorrectly shows the time as 4:00 pm CET. Hi @John.Murray thank you for bringing our attention to that!Working on a new picture right now, and will replace the current one asap :) One of my colleagues just tried using the registration link but got this response from the Global Masters page it leads to:
Hi @John.Murray, could be if the onboarding challenge is not completed - the one which unlocks the Global Masters program. Maybe you could send me in DM his/her email address? I will forward an invitation by email, no additional registration will be needed.
Announcement
Anastasia Dyubaylo · Apr 3, 2023
Hi Developers!
We have great new articles for your to read and enjoy, thanks to our wonderful participants of the 4th InterSystems Tech Article Contest: InterSystems IRIS Tutorials!
🌟 24 AMAZING ARTICLES 🌟
And now it's time to announce the winners!
Let's meet the winners and their articles:
⭐️ Expert Awards – winners selected by InterSystems experts:
🥇 1st place: InterSystems Embedded Python in glance by @Muhammad.Waseem
🥈 2nd place: InterSystems Embedded Python with Pandas - Part 1 by @Rizmaan.Marikar2583
🥉 3rd place: SQLAlchemy - the easiest way to use Python and SQL with IRIS's databases by @Heloisa.Paiva
⭐️ Community Award – winner selected by Community members, article with the most likes:
🏆 Setting up VS Code to work with InterSystems technologies by @Maria.Gladkova
And...
⭐️ We'd like to reward some more authors for the number of contributions:
@Robert.Cemper1003: 4 articles!
@Heloisa.Paiva: 3 articles!
@Irene.Mikhaylova: 3 articles!
These guys will get Magic Keyboard Folio for iPad or Bose Soundlink Micro Bluetooth Speaker!
Let's congratulate all our heroes, who took part in the Tech Article contest #4:
@Robert.Cemper1003
@Heloisa.Paiva
@Muhammad.Waseem
@wang.zhe
@Irene.Mikhaylova
@Maria.Gladkova
@Yone.Moreno
@Akio.Hashimoto1419
@Julian.Matthews7786
@Daniel.Aguilar
@water.huang
@Oliver.Wilms
@Rizmaan.Marikar2583
@姚.鑫
@Zhong.Li7025
@Jude.Mukkadayil
@Roger.Merchberger
THANK YOU ALL! You have made an incredible contribution to our Dev Community!
The prizes are in production now. We will contact all the participants when they are ready to ship.
Congratulation to all the winners and participants 👏👏Thanks organizers for providing this amazing opportunity to participate
Awesome! Thanks for the prize and congratulations to the winners and all participants! Python WON
One of the winner's articles uses my project SQLAlchemy-IRIS. And one more could use it too, and there is an example with it in the comments. Congrats to the winners and thank you to everyone who took time to contribute :) Congratulations to all, amazing articles
Announcement
Anastasia Dyubaylo · Mar 10, 2023
Hello and welcome to the Developer Ecosystem Winter News!
This winter (or summer for those of you from another hemisphere) we've had a lot of online and offline activities in the InterSystems Developer Ecosystem.
In case you missed something, we've prepared for you a selection of the hottest news and topics to catch up on!
News
🔥 Top 2022 Articles for InterSystems Developers
🔥 Top Questions about InterSystems Data Platforms for 2022
🔥 Top 2022 Applications on InterSystems Open Exchange
🔥 Top 2022 Videos for InterSystems Developers
👋 See what you've been up to in 2022!
💡 InterSystems Ideas News #2, #3, #4
🔥 New Global Masters badges - for reviews on Open Exchange
📝 Updated Vulnerability Handling Policy
📝 February 15, 2023 – Alert: Use of Large Pages for Shared Memory on Windows Platforms
📝 Speeding up AND becoming more predictable - updates to our release cadence
✅ InterSystems Supported Platforms Update Feb-2023
👋 The Second Batch of Caelestinus - a Digital Health Interoperability and FHIR Startup Incubator is Starting!
Contests & Events
InterSystems Developer Tools
Contest Announcement
Kick-off Webinar
Technology Bonuses
Time to Vote
Technical Bonuses Results
Winners Announcement
Meetup with Winners
Advent of Code
Contest Announcement
Winners Announcement
Community Roundtables
Modern development process with InterSystems IRIS
AI / ML
📄 [DC Contest] Spanish Tech Article Contest: Second Edition
⏯️ [Webinar] Deltanji demo: source control tailored for InterSystems IRIS
⏯️ [Webinar] Validating FHIR profiles with InterSystems IRIS for Health
☕️ [Meetup] First Dutch HealthShare user group meeting
Latest Releases
⬇️ InterSystems announces availability of InterSystems IRIS, IRIS for Health, & HealthShare Health Connect 2022.1.2
⬇️ InterSystems announces availability of InterSystems IRIS, IRIS for Health, & HealthShare Health Connect 2021.1.3
⬇️ InterSystems announces General Availability of InterSystems IRIS, IRIS for Health, HealthShare Health Connect, & InterSystems IRIS Studio 2022.3
⬇️ InterSystems IRIS, IRIS for Health, & HealthShare Health Connect 2022.3 developer previews
Preview 3
Preview 4
Preview 5
Preview 6
⬇️ InterSystems IRIS, IRIS for Health, & HealthShare Health Connect 2023.1 developer previews
Preview 1
Preview 2
⬇️ InterSystems Package Manager
Release 0.5.2
⬇️ IAM 3.0 Release Announcement
⬇️ VS Code ObjectScript releases v2.6.0
⬇️ Health Data De-ID Early Access Program
⬇️ New bio and pinned posts in your profile!
⬇️ What's new on Open Exchange
Best Practices & Key Questions
🔥 Best Practices of Winter 2022
Splitting ORU Messages using ObjectScript and DTL
Data models in InterSystems IRIS
Tips and tricks of the brand new LOAD DATA command
Create Stored Procedures using Embedded Python
Getting an Angular UI for your InterSystems IRIS application in 5 minutes
Working with Several ObjectScript Projects simultaneously Using VSCode and Docker in InterSystems IRIS
Introduction to Web Scraping with Embedded Python - Let’s Extract python job’s
UI for Ensemble Workflow in Angular
Implementing IRIS Integrations with .NET or Java using PEX
Display Management Portal Dashboard by using Python Flask web and Bootstrap Frameworks with the help of embedded python
❓ Key Questions of Winter 2022: December, January, February
💡 How to add InterSystems certification to your DC profile
People and Companies to Know About
👋 Yuxiang Niu - New Developer Community Moderator
🌟 Global Masters of Winter 2022: December, January, February
Top Open Exchange Developers and Applications for 2022
Top InterSystems Community Contributors for 2022
Job Opportunities
💼 Internship Available
💼 Senior Interoperability Engineer - Remote
💼 Senior Interface Engineer opportunity - Remote
So...
Here is our take on the most interesting and important things!
What were your highlights from this past season? Share them in the comments section and let's remember the fun we've had!
Article
Maria Gladkova · Mar 15, 2023
Hi all!
In this article I would like to review those VS Code extensions which I use myself to work with InterSystems and which make my work much more convenient. I am sure this article will be useful for those who are just starting their journey to learn InterSystems technologies. However, I also hope that this article could be useful for experienced developers with many years of experience and open up new possibilities for them when using VS Code for development.
I recommend that everyone who works with InterSystems has these extensions installed and in this article I will show how to use some of them.
You can read more about the functionality and use of each extension in the Extensions section of VS Code, there you can also download, update and uninstall extensions:
After installation, extension icons appear on the side or at the bottom of the code editor.
Mandatory extensions
I think it makes sense to start our journey with those basic extensions, without which working with InterSystems in VS Code becomes impossible.
The InterSystems Server Manager Extension for VS Code assists in specifying server connections.
The InterSystems ObjectScript Extension for VS Code assists in writing and compiling code files.
The InterSystems Language Server Extension for VS Code provides a language server implementation for ObjectScript, enabling coloring, code completion, linting, and more.
Together, these extensions provide developers with a streamlined way of creating, testing, and deploying full-stack applications built on InterSystems.
Additional extensions
In addition to the basic necessary extensions, VS Code offers many other extensions. You can write code without them, but using them makes development more efficient when using any technology stack, including InterSystems technologies. I will describe a few which seem to me to be a must-have.
The Docker extension makes the management of dockerised projects a little easier. You can automatically generate a Dockerfile for projects, run images and manage running containers.
SQLTools Driver for InterSystems IRIS and SqlTools - are two very handy extensions that work together. Using them, you can create and execute the database SQL queries in VS Code without having to go into the management portal and perform sql queries to interact with the table contents there.
Today, it's hard to imagine developing a project without using version control. Most often this is Git, and Visual Studio Code has minimal support for it right out of the box. But if that's not enough for you, check out the next two extensions:
Git Graph - shows branches and their status schematically. This is useful in situations where you need to quickly understand the status of branches, e.g. when they merge.
Git Lens - allows you to see the history of changes to the highlighted line and its author.
It is indispensable for teamwork!
EditorConfig - an extension to improve code appearance, requires writing .editorconfig file, in which you can specify any code formatting settings. It's important to note that by default such functionality can be implemented by InterSystems Language Server extension for VS Code, to apply standard ObjectScript code formatting in VS Code you need to use key combination: Windows - [Shift + Alt + F], Mac - [Shift + Option + F], Ubuntu - [Ctrl + Shift + I]. But when using .editorconfig file you can specify your own code formatting for different files within the project.
In this article, I've only looked at the extensions I've used myself. I would be grateful if you could take the time to write in the comments what else can be used to make development more convenient. Then this article will become even more useful! Very nice initial How-To! Thank you especially for the animated GIFs! Excellent read, will be installing a couple of these now! Hi @Maria.Gladkova, Nice article and very well explained. Thanks Very nice article @Maria.Gladkova to start developing with VSCode! The most noteworthy extensions I'm using too in my VSCode setup:
Encode decode (convert text to other formats like Base64)
OpenAPI (swagger) Editor (specifying & documenting your REST api endpoints)
WSL (enabling direct use of the Windows Subsystem for Linux in VSCode)
Thank you very much, I've already installed and tried some of them out! Good luck coding! Thanks! Thank you!
Article
Yuri Marx Pereira Gomes · Apr 13, 2023
It is a recommended security practice to login into sensitive Administrator Portals without any input passwords. Thus, it is necessary to identify and authenticate the users correctly. A common technique employed by web portals and mobile applications is to use Google social login. Today, Google Gmail has 2 billion users (source: https://www.usesignhouse.com/blog/gmail-stats). Therefore, it is a perfect shared login service to utilize to login InterSystems IRIS users when they need to manage their instances. This article will detail all the steps to embed Google Login into your InterSystems Management Portal.
Register your InterSystems instance in the Google Console
1. Go to https://console.cloud.google.com and log in with your Google user account.2. On the header click Select a project:
3. Click the button NEW PROJECT:
4. Create a sample project for this article called InterSystemsIRIS and click the button CREATE:
5. Go to the Header again and select the created project InterSystemsIRIS hyperlink in the table:
6. Now the selected project is the working one:
7. In the header look for credentials on the Search field and choose API credentials (third option for this image):
8. On the top of the screen, click the + CREATE CREDENTIALS button and select OAuth 2.0 Client ID option:
9. Now click CONFIGURE CONSENT SCREEN:
10. Choose External (any person who has Gmail is able to use it) and click the CREATE button:
11. In Edit app registration, complete the field values as follow:App Information (use your email for user support email):
App Logo (save any vertical InterSystems Logo on your computer and use it here):
App Domain (set home page with the value http://localhost:52773/csp/sys/%25CSP.Portal.Home.zen)
For Authorized domains, it is not necessary to set anything because this sample will use localhost. Set the developer contact information with your email and click the SAVE AND CONTINUE button:
12. Click ADD OR REMOVE SCOPES and select the following scopes, scroll the dialog, and click the UPDATE button:
13. Your non-sensitive, sensitive, and restricted scopes are listed. Accept all of them and click the SAVE AND CONTINUE button:
14. Include your email into the Test users list (using the +ADD USERS button) and click the SAVE AND CONTINUE button:
15. The wizard shows you the Summary of the filled fields. Scroll the screen and click the BACK TO DASHBOARD button.16. Now, it is time to configure the credentials for this new project. Select the option Credentials:
17. Click the button +CREATE CREDENTIALS and select OAuth client ID (we need to take this step again because now we have OAuth consent screen defined):
18. Select Web application in the Application Type and InterSystems IRIS in the Name field:
19. Configure JavaScript origins and redirects (click +ADD URI to get more fields) as follows and click the SAVE button:
JavaScript URI 1: http://localhost:52773
JavaScript URI 2: http://localhost
Redirect URI 1: http://localhost:52773
Redirect URI 2: http://localhost
Redirect URI 3: http://localhost:52773/csp/sys/dc.login.GoogleLogin.cls
20. Now we have a Client ID and a Client Secret. You should copy them to a text file on your disk or save the data using DOWNLOAD JSON:
Now we will embed Google Login to our local InterSystems IRIS instance.
InterSystems IRIS Delegated Authentication Mechanism to the Management Portal
InterSystems IRIS allows us to use a few authentication options, including Instance Authentication (a default option that uses a user and a password managed by the IRIS instance), LDAP (users managed by an enterprise repository), and Delegated Authentication (for customized authentication mechanism).We will choose Delegated Authentication because this is the option where the login uses OAuth and a custom code to get user credentials and authenticate users without the input passwords. When using OAuth, the OAuth server (Google in our use case) will authenticate and return to the InterSystems IRIS (OAuth client) the user details logged in.In our example, we want to set up Delegated Authentication to the Management Portal (csp/sys application). To make it happen, you need to take the following steps:
Create a class extending %CSP.Login and write the custom HTML, JavaScript, and CSS code for the customized login. In this article sample we will embed a Google button to log in with the Google user.
Create and write Object Script in the macro ZAUTHENTICATE.mac with the custom backend authentication login logic.
Enable Delegated Authentication to the InterSystems IRIS.
Set up Delegated authentication and the custom login page (the class extending %CSP.Login) for the /csp/sys web application (Management Portal web application).
All these steps should be done in the %SYS namespace.
Using a sample application to learn how to embed Google Login into Management Portal
To learn how to embed Google Social Login into an instance of the InterSystems IRIS, we will use the application Google IRIS Login (https://openexchange.intersystems.com/package/Google-IRIS-Login). Follow these steps in order to get it:
1. Clone/git pull the repo into any local directory:
git clone https://github.com/intersystems-community/intersystems-iris-dev-template.git
2. Go to the .env file and input your CLIENT_ID generated in your Google Cloud Console in the first part of this article.3. Open the terminal in this directory and call the command to build InterSystems IRIS in a container
docker-compose build
4. To run the InterSystems IRIS in a container, do the next:
$ docker-compose up -d
5. Access the Management Portal (http://localhost:52773/csp/sys/%2525CSP.Portal.Home.zen) and use your Google user to enter:
Ready! In the upcoming sections, we will see all the steps one needs to configure and develop inside IRIS to embed Google Social Login.
Creating a custom Login Page extended from %CSP.Login
To embed the Google Login into the Management Portal we need to create a new Login page extending from %CSP.Login. This allows us to reuse the default Login Page but requires adding the necessary source code for supporting Google Login. The custom login page will override the following class methods:
OnLoginPage: used to write the HTML and JavaScript code to render the login form with the Google Login button.
DrawHead: employed to add JavaScript code that will persist Google Login credentials returned into cookies for the backend logic use.
GoogleLogin.cls source code
Important actions on this page:1. We got CLIENT_ID and LOGIN_URI from the env file to use as parameters for the Google Login button:
Set envClientId = ##class(%SYSTEM.Util).GetEnviron("CLIENT_ID")
Set envLoginURI = ##class(%SYSTEM.Util).GetEnviron("LOGIN_URI")
2. Before the content, we needed to load the Google JavaScript library
<script src="https://accounts.google.com/gsi/client" async defer></script>
3. Our next step was to write the HTML code to render the Google button using LOGIN_URI and CLIENT_ID environment variables collected from the .env file:
<div id="g_id_onload"
data-client_id="#(envClientId)#"
data-context="signin"
data-ux_mode="popup"
data-callback="handleCredentialResponse"
data-login_uri="#(envLoginURI)#"
data-auto_prompt="false">
</div>
<div class="g_id_signin"
data-type="standard"
data-shape="rectangular"
data-theme="outline"
data-text="signin_with"
data-size="large"
data-onsuccess="onSignIn"
data-logo_alignment="left">
</div>
4. On the DrawHead class method, we wrote JavaScript functions to get the Google user credentials and store them in cookies for the backend use:
function setCookie(name,value,days) {
var expires = "";
if (days) {
var date = new Date();
date.setTime(date.getTime() + (days*24*60*60*1000));
expires = "; expires=" + date.toUTCString();
}
document.cookie = name + "=" + (value || "") + expires + "; path=/";
}
function newSession() {
eraseCookie('email');
window.location.reload();
}
function eraseCookie(name) {
// This function will attempt to remove a cookie from all paths.
var pathBits = location.pathname.split('/');
var pathCurrent = ' path=';
// do a simple pathless delete first.
document.cookie = name + '=; expires=Thu, 01-Jan-1970 00:00:01 GMT;';
for (var i = 0; i < pathBits.length; i++) {
pathCurrent += ((pathCurrent.substr(-1) != '/') ? '/' : '') + pathBits[i];
document.cookie = name + '=; expires=Thu, 01-Jan-1970 00:00:01 GMT;' + pathCurrent + ';';
}
}
function deleteAllCookies() {
const cookies = document.cookie.split(";");
for (let i = 0; i < cookies.length; i++) {
const cookie = cookies[i];
const eqPos = cookie.indexOf("=");
const name = eqPos > -1 ? cookie.substr(0, eqPos) : cookie;
document.cookie = name + "=;expires=Thu, 01 Jan 1970 00:00:00 GMT";
}
}
// called when page is loaded
function pageLoad()
{
// see if we can give focus to the UserName field:
if (self.document.Login && self.document.Login.IRISUsername) {
self.document.Login.IRISUsername.focus();
self.document.Login.IRISUsername.select();
}
return true;
}
function decodeJwtResponse(token) {
var base64Url = token.split('.')[1];
var base64 = base64Url.replace(/-/g, '+').replace(/_/g, '/');
var jsonPayload = decodeURIComponent(window.atob(base64).split('').map(function(c) {
return '%' + ('00' + c.charCodeAt(0).toString(16)).slice(-2);
}).join(''));
return JSON.parse(jsonPayload);
}
function handleCredentialResponse(response) {
const responsePayload = decodeJwtResponse(response.credential);
console.log("ID: " + responsePayload.sub);
console.log('Full Name: ' + responsePayload.name);
console.log('Given Name: ' + responsePayload.given_name);
console.log('Family Name: ' + responsePayload.family_name);
console.log("Image URL: " + responsePayload.picture);
console.log("Email: " + responsePayload.email);
setCookie('email', responsePayload.email);
setCookie('googleToken', response.credential);
if(responsePayload.email !== null) {
document.getElementsByName('Login')[0].submit();
}
}
5. To see all the content for the Login Page go to src > cls > dc > login > GoogleLogin.cls file.
Creating the backend code to authenticate Google users
To write the backend logic to handle custom login using delegated mechanism, it is necessary to apply a macro with the name ZAUTHENTICATE.mac into %SYS namespace.
ZAUTHENTICATE.mac source code
Important actions in this file:1. Define and store an encrypted password for the new user selected in the Google Login prompt:
Set GooglePassword = $SYSTEM.Util.GetEnviron("GOOGLE_PASSWORD")
Set GlobalPassword = $EXTRACT(##class(dc.login.CypherUtil).DoAESCBCEncrypt(GooglePassword),1,20)
2. Refer to the Management Portal application (csp/sys) for Google Login:
Set App = $SYSTEM.Util.GetEnviron("ISC_App")
Set:App="" App = "/csp/sys"
Set GN = "^%ZAPM.AppsDelegate"
If $EXTRACT(App,*)'="/" {
Set App=App_"/"
}
3. Get the Google user selected and stored in the email cookie:
Set Email = %request.GetCookie("email")
4. Test if the user already exists. If not, create the user as a Superuser (My choice is the %All role, but you can pick another option, for example, the %Developer role). If the user already exists, just log in:
Set EmailUser = $PIECE(Email,"@")
Set qry = "select * from Security.Users where EmailAddress = ?"
Set tStatement = ##class(%SQL.Statement).%New()
Set qStatus = tStatement.%Prepare(qry)
Set rset = tStatement.%Execute(Email)
While rset.%Next() {
Set UserExists = 1
}
If UserExists = 1 {
Set Username = rset.Name
Set Password = GlobalPassword
Quit $SYSTEM.Status.OK()
} Else {
Set $nameSpace = "%SYS"
if '##class(Security.Users).Exists($PIECE(Email,"@")) {
Set status = ##class(Security.Users).Create($PIECE(Email,"@"),"%ALL",GlobalPassword,$PIECE(Email,"@"),"","","",0,1,"",1,0,"","","","")
Set status = ##class(Security.Users).Get($PIECE(Email,"@"),.properties)
Set properties("EmailAddress")=Email
Set status = ##class(Security.Users).Modify($PIECE(Email,"@"), .properties)
If status = 1 {
Set Username = $PIECE(Email,"@")
Set Password = GlobalPassword
Quit $SYSTEM.Status.OK()
}
}
}
5. Compile these files into the “%SYS” namespace.
It is time to set some parameters to ensure the delegated authentication using the custom source code written above.
Adjust the settings to ensure delegated login
1. Go to the Management Portal (http://localhost:52773/csp/sys/%2525CSP.Portal.Home.zen) and log in with _system/sys credentials.2. Proceed to System Administration > Security > System Security > Authentication/Web Session Options:
3. The option “Allow Delegated authentication” must be checked:
4. Now go to System Administration > Security > Users and select the user CSPSystem. The user must have the role DB_IRISSYS or %All role (it is necessary because this user is utilized to run the login page and the authenticate.mac logic with the permissions required to execute it):
5. Move to the System Administration > Security > Applications > Web Applications and select the /csp/sys application.6. In the "Allowed Authentication Methods" field, check the option "Delegated.7. The Login Page field must have dc.login.GoogleLogin.cls as a value (we need it to call our custom login page, instead of the IRIS default page):
8. Now to ensure the correct functioning, attach Shell to your IRIS docker instance:
9. Now restart the page from the prompt writing and execute the command "iris restart iris":
10. Finally, go to the Login page again.
Now you have Google as an option to log in. Enjoy it! wow - what an incredibly in-depth tutorial! thank you @Yuri.Gomes for the time you took putting this together for the Community! Many thanks! @Yuri.Gomes Thank you so much for this great work - tutorial, and application! 👏👏
Looks like you implemented the idea:
💡Please add google oauth authorization to login to the management portal💡
from Ideas Portal ✨
Many thanks!👏 Thanks! Yes, I implemented it. Thank you, @Yuri.Gomes! Can we have the similar implementation for GitHub OAuth too? Github is the most popular site for developers, so authentication via GItHub will be very handy for developers. Yes, I will work on Github too.
Announcement
Danusa Calixto · Apr 14, 2023
Hey Developers,
We'd like to invite you to join our next 🏆 InterSystems Tech Article Contest in Portuguese 🏆
Duration: May 12 - Jun 12, 2023
We can't wait for your articles! Good luck 🍀
Question
Humza Arshad · May 5, 2023
I'm working with a client who has InterSystems in his hospital to the management of patients and nurses. Now he want to develop a web app which can schedule nurse sift. Is there any way I can authenticate the user from his hospital InterSystems and get data from the system when ever the user login through the web app. @Humza.Arshad
You can create a REST API/ SOAP API, or any other kind of protocol/technology, to get authentication, retrieve and send data to IRIS.
See the documentation:
REST
SOAP
These other two link are two Open Exchange apllication to create Rest Services and Form UI.
RESTForms2
RESTFormsUI2
Search in the Leraning Portal for some course that help you.
Best Regards.
Announcement
Anastasia Dyubaylo · Oct 10, 2022
Hi Community!
We'd like to invite you to join our next contest to share your FHIR knowledge:
🏆 InterSystems IRIS for Health Contest: FHIR for Women's Health 🏆
Submit an application that uses InterSystems FHIR or InterSystems Healthcare Interoperability!
Duration: November 14 - December 4, 2022
Prizes: $13,500!
>> Submit your application here <<
The topic
💡 Healthcare Interoperability Solutions – FHIR 💡
Develop any interoperability FHIR solution or Healthcare Interoperability solution or a solution that helps to develop or/and maintain interoperability solutions using InterSystems IRIS for Health, Health Connect, or FHIR server.
In addition, we invite developers to try their hand at solving one of the global issues. This time it will be Women's Health.
We encourage you to join this competition and build solutions aimed at solving the following issues:
You will receive a special bonus if your application can help pregnant patients discover trends in tracking pregnancy symptoms and/or build an integration to share symptoms and pregnancy journal notes with a partner application.
There will also be another bonus if you prepare and submit a FHIR dataset related to women’s digital health in these areas: pregnancy tracking/monitoring, parenthood support, or menopause patient education.
General Requirements:
Accepted applications: new to Open Exchange apps or existing ones, but with a significant improvement. Our team will review all applications before approving them for the contest.
The application should work either on InterSystems IRIS for Health Community Edition or Health Connect Cloud.
The application should be an Open Source application and published on GitHub.
The README file to the application should be in English, contain the installation steps, and contain either the video demo or/and a description of how the application works.
🆕 Contest Prizes:
1. Experts Nomination – winners will be selected by the team of InterSystems experts:
🥇 1st place - $5,000
🥈 2nd place - $3,000
🥉 3rd place - $1,500
🏅 4th place - $750
🏅 5th place - $500
🌟 6-10th places - $100
2. Community winners – applications that will receive the most votes in total:
🥇 1st place - $1,000
🥈 2nd place - $750
🥉 3rd place - $500
Note: If several participants score the same amount of votes, they all are considered winners, and the money prize is shared among the winners.
Important Deadlines:
🛠 Application development and registration phase:
November 14, 2022 (00:00 EST): Contest begins.
November 27, 2022 (23:59 EST): Deadline for submissions.
✅ Voting period:
November 28, 2022 (00:00 EST): Voting begins.
December 4, 2022 (23:59 EST): Voting ends.
Note: Developers can improve their apps throughout the entire registration and voting period.
Who Can Participate?
Any Developer Community member, except for InterSystems employees (ISC contractors allowed). Create an account!
Developers can team up to create a collaborative application. Allowed from 2 to 5 developers in one team.
Do not forget to highlight your team members in the README of your application – DC user profiles.
Helpful Resources:
✓ Example applications:
FHIR Server Template
iris-healthtoolkit-template
interoperability-embedded-python
FHIR HL7 SQL Demo FHIR DropBox
HL7 and SMS Interoperability Demo
IrisHealth Ensdemo
UnitTest DTL HL7
Healthcare HL7 XML
FHIR Interoperability Examples
FHIR-Orga-dt
FHIR Peudoanonimisation Proxy
FHIR-client-java
FHIR-client-.net
FHIR-client-python
FHIR related apps on Open Exchange
HL7 applications on Open Exchange
✓ Online courses:
FHIR Integrations
HL7 Integrations
Learn FHIR for Software Developers
Exploring FHIR Resource APIs
Using InterSystems IRIS for Health to Reduce Readmissions
Connecting Devices to InterSystems IRIS for Health
Monitoring Oxygen Saturation in Infants
FHIR Integration QuickStart
✓ Videos:
6 Rapid FHIR Questions
SMART on FHIR: The Basics
Developing with FHIR - REST APIs
FHIR in InterSystems IRIS for Health
FHIR API Management
Searching for FHIR Resources in IRIS for Health
✓ For beginners with IRIS:
Build a Server-Side Application with InterSystems IRIS
Learning Path for beginners
✓ For beginners with ObjectScript Package Manager (ZPM):
How to Build, Test and Publish ZPM Package with REST Application for InterSystems IRIS
Package First Development Approach with InterSystems IRIS and ZPM
✓ How to submit your app to the contest:
How to publish an application on Open Exchange
How to submit an application for the contest
Need Help?
Join the contest channel on InterSystems' Discord server or talk with us in the comment to this post.
We can't wait to see your projects! Good luck 👍
By participating in this contest, you agree to the competition terms laid out here. Please read them carefully before proceeding. Excited to see the creativity in this challenge! Congrats for this fundamental topic, great! Great topic for the contest. Bravo! It's high time we delved deeper into this topic! Hey Developers,
The recording of the Kick-off Webinar is already available on InterSystems Developers YouTube:
⏯ [Kick-off Webinar] InterSystems FHIR for Women's Health Contest
Developers!
The first application has been added to the contest!
FemTech Reminder by @KATSIARYNA.Shaustruk
Check it out! Hi, Community!
Only 2 days left to register for the contest!
Hurry up to upload your application!
Announcement
Anastasia Dyubaylo · Oct 17, 2022
Hello Community,
The 1st InterSystems Idea-A-Thon is over. As a result, 75 brilliant ideas – an absolute success, wow! 🤩
Thank you all for participating with your ideas and contributing with your votes and comments!
And now we're so glad to announce the winners...
Expert Award
🏆 Change Management for Editors inside of Portal submitted by @Scott.Roth
Community Award
To show our appreciation to our participants, we've decided to expand our Community nomination and award several top-voted ideas:
🌟 Nodejs with IRIS a dynamic platform submitted by @Sharafat.Hussain
🌟 E-learning for job submitted by @Andre.LarsenBarbosa
🌟 Code snippets library submitted by @Danny.Wijnschenk
All the winners will receive one of our specially prepared prizes: LEGO Star Wars™ R2-D2™ / BOSE Sleepbuds™ II / BOSE SoundLink Flex Bluetooth® speaker bundle.
🔥 In addition to our winners, we'd like to highlight all our participants and their bright ideas. Let's meet all of them:
Spoiler
Modernize terminal
Use the built-in feature engineering in AutoML to transform datasets
Add a wizard similar to the SOAP wizard to generate a REST client from OpenAPI specification
New reward: IRIS developer license
IRIS and ZPM(Open Exchange) integration
Bare minimum start of IRIS for docker build
New rewards
BPL, DTL, Business Rule Editor in VSCode
Articles and answered questions recommendations
RPMShare - Database solution for remote patient monitoring (RPM) datasets of high density vitals
Move users, roles, resources, user tasks, Mappings (etc) to a seperate Database, other than %SYS, so these items can be mirrored
Create a UI for convenient and easy transfer of projects (classes, globals, applications, users, roles, privileges, grants, namespace mapping, SQLgateways, libraries, etc.) to other system instances for fast deployment.
InterSystems Ideas - Long Term
Cloud Service Starter Kit
PM platform
Tool to convert legacy dot syntax code to use bracket syntax
Add basic tutorial of Docker or point to a Docker tutorial in Documentation
Better handle whitespace in Management Portal Text entry
Reserve licenses
Improve Production Migration From TST to PRD
Data Analyzer
Create front-end package based on CSS and JS to be used in NodeJS and Angular projects
Expose Global Masters Badges
VS Code: Index local workspace folder
Add a chatbot to the Global Masters hub
PDF reports for IRIS BI
Sample code share opportunity
Common Data Modelling
CI/CD support
Journal file analysis/visualization
A Dynamic Cheat Sheet to lookup for Common Core Functions for Reusability
Version History for Classes
Visual programming language
Interoperability Wizard
Connectivity of DeepSee with External Database
Better unicode support
Dark Mode for Studio!
HealthShare Patient Unmerge Ooopses
Editing category of the idea after adding it
Group events for people outside the community
TTTC
Embedded Python: Add a built-in variable to represent class
Create a new model type option for IRIS database: blockchain
Add the option to call class parameters in Embedded Python
A client to export codes from specified packages from IRIS/Cache
Reagent Consumption Module - Auto Consumption of Lab Machine Reagents
Cache Journal Switch Schedule
Colour Background on Ward / Clinical Areas Floorplans
Production Audit Report
Run Jasperreports from ObjectScript and IRIS Adapter
Business Operation Testing mode per namespace
Do not change formatting when compiling through GUI
File Service class to allow multiple instances to share access to one directory
Native RPC API for ObjectScript
change data chapture
Expose internal code elements (classes, routines etc) through SFTP, CIFS/SMB or similar established protocol
LDAP Authentication method by default on Web Applications
Monitoring and Programatic way of Starting/Stoping Gateways
Improve journal display in IRIS admin portal
Adapting tools for people with special needs and/or disabilities 🌐🔰🦽🦼♿
Backup button before importing
Add wizard to create class with its properties
Create query builder
Linux: iris session [command line] get commands from a file
String format to numeric values in ZEN.proxyObject
The ability to export current settings to a %Installer Manifest
Linking I service to JIRA system
I service Flags
Patient Initiated Follow Up - Adding a document to an ROPWL
Mirror Async Member Time Delay in Applying Journals
Please add google oauth authorization to login to the management portal
All Idea-A-Thon participants will get our special InterSystems Branded T-shirt.
OUR BIG CONGRATULATIONS TO ALL WINNERS AND PARTICIPANTS!
Thank you for such great contributions to the official InterSystems feedback portal 💥
Important note: The prizes are in production now. We will contact all the participants when they are ready to ship. Thanks for the opportunity, not being a developer, it was harder to participate in more technical contests. Thank you #InterSystems for arranging #Idea-A-Thon. It is great to keep on track of innovations while carrying the legacy. Congrats winners! Thanks!!! Congratulation to all the winners Congratulations to the winners! Thanks for giving us this opportunity to share our ideas! Congratulations to the winners and all participants! Amazing ideas, unexpectedly large amount of new ideas! It was a great experience for me to participate in organization of this event. Thank you! Congrats to the winners! Thanks for giving us a way to express ideas and changes that we have pondered for years. Isn't it great when your ideas come to life so quickly... Check out our last few posts on the Developer Community, where we have been discussing our new Production component driver for Deltanji source control - a solution for the winning entry!
Great minds think alike @Scott.Roth, congratulations on winning the contest.Link to most recent post here: https://community.intersystems.com/post/source-control-interoperability-productions 75! I'm so surprised by how many bright ideas community kept in secret that were revealed now! Thanks, Ideas Portal team @Anastasia.Dyubaylo @Vadim.Aniskin and @Raj.Singh5479 for running the idea-a-thon!
It looks like the next step is the implementation marathon ;)
Announcement
Olga Zavrazhnova · Nov 6, 2022
Hi Developers!
InterSystems continues the Developer Meetup event series. The next one will happen on November 17th from 5:30 pm-8 pm ET in Boston, MA, USA.At this meetup, you will learn more about Kubernetes, Mirantis Lens tool, and how to run Lens with InterSystems IRIS IKO (InterSystems Kubernetes Operator).
Food and drink will be provided.
> Register here <
Agenda:👉 "InterSystems Overview and Developer Resources" by @Dean.Andrews2971, Head of Developer Relations, InterSystems👉 "Mirantis Overview and Developer Resources" by Tommy Decker, Account Executive, Mirantis👉 "Scaling Stateful Workloads in Kubernetes" by @Robert.Kuszewski, Product Manager - Developer Experience, InterSystems👉 "Demo of Lens with InterSystems IRIS IKO (InterSystems Kubernetes Operator)" by Toby Goodlock, Solution Architect, Mirantis
⏱ Date and Time: November 17th from 5:30pm-8pm ET📍 Location: Democracy Brewing, Boston
Announcement
Anastasia Dyubaylo · Dec 16, 2022
Hi Community,
Enjoy watching the new video on InterSystems Developers YouTube:
⏯ Using System Functions in InterSystems ObjectScript
See how to use the system functions in ObjectScript to quickly perform operations. These functions allow you to manipulate strings, execute class methods, and more. You’ll learn the syntax for running system functions and see how to use the values they return in other functions and commands.
Enjoy watching and stay tuned! 👍