Connection strings…

While working against the K2 API you will find that there are a number of connection strings used to make the connection to the various K2 services such as User Role Manager, workflow server, the smartobject server.  There is a Class called SCConnectionStringBuilder provided by K2 which makes this task simple and consistent.

//we now have a connection string builder helper

SCConnectionStringBuilder connectionStrB= new SCConnectionStringBuilder();

connectionStrB.Host = “servernameFromConfig”;

connectionStrB.Integrated = true;

connectionStrB.IsPrimaryLogin = true;

connectionStrB.Port = portNumberFromConfig;

Most of the services except the workflow service listen on the default port for host server on 5555. The workflow service is on 5252 (unless of course you changed these port numbers during the configuration of K2)

The connection string is then retrieved and used as follows:


Published by


Are you ready to Transform your Enterprise?

Leave a Reply

Please log in using one of these methods to post your comment: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s