views:

64

answers:

1

I am developing a proof-of-concept website site in C# that will take URL Query strings, match that to a paticular Groove workspace, and then invite the user into that space if they don't have it. I have the connect-to Groove Data Bridge, find the workspace, read the workspace members portion working just fine.

I've come accross a stumbling block on the auto-invite, though. I am running this as a free-standing website "bridge" so I am trying to run this purely from the web server. I have the Groove Identity for the person I want to invite from the database as a string:

CurrUserIdentity = grooveIdentity://nzkth68eqzgktrb9sbr....

But, I cannot find out how to turn the string into the true GrooveMember.Member object that then be invited. What is the easiest way to invite, in this case?

A: 

Found it, finally:

GrooveMembers.GrooveMembers AddMember = new GrooveMembers.GrooveMembers();
AddMember.GrooveRequestHeaderValue = new GrooveMembers.GrooveRequestHeader();
AddMember.GrooveRequestHeaderValue.GrooveRequestKey = someString; //Whatever used in your envronment
AddMember.GrooveRequestHeaderValue.GrooveIdentityURL = id.URI; //URI of the local Groove identity or the Groove Data Bridge
AddMember.Url = someOtherString /*Local web string or remote host*/ + space.Members;//A property of the space you are inviting the tuser into
GrooveMembers.Member[] Members = AddMember.Read();//actually connects to the service

GrooveMembers.Member newMember = new GrooveMembers.Member();
newMember.URI = userIdentity;//A string stripped from the database and TRIMmed
newMember.Name = userFullName;//A string also pulled from the database DisplayNeme\GrooveDomain
string userContact = "/GWS/Groove/2.0/Contacts/" + userIdentity.Replace("://", "/");
newMember.Contact = userContact;// A string formatted by replacing :// with / adding "/GWS/Groove/2.0/Contacts/" to the front of the Groove Identity
newMember.Role = "$Telespace.Member";

AddMember.Create(newMember);

GrooveMembers.GrooveMembers AddMember = new GrooveMembers.GrooveMembers();
AddMember.GrooveRequestHeaderValue = new GrooveMembers.GrooveRequestHeader();
AddMember.GrooveRequestHeaderValue.GrooveRequestKey = someString; //Whatever used in your envronment
AddMember.GrooveRequestHeaderValue.GrooveIdentityURL = id.URI; //URI of the local Groove identity or the Groove Data Bridge
AddMember.Url = someOtherString [Local web string or remote host] + space.Members [A property of the space you are inviting the tuser into];
GrooveMembers.Member[] Members = AddMember.Read();//actually connects to the service

GrooveMembers.Member newMember = new GrooveMembers.Member();
newMember.URI = userIdentity;//A string stripped from the database and TRIMmed
newMember.Name = userFullName;//A string also pulled from the database DisplayNeme\GrooveDomain
string userContact = "/GWS/Groove/2.0/Contacts/" + userIdentity.Replace("://", "/");
newMember.Contact = userContact;// A string formatted by replacing :// with / adding "/GWS/Groove/2.0/Contacts/" to the front of the Groove Identity
newMember.Role = "$Telespace.Member";

AddMember.Create(newMember);
Matthew Damp