TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Adong Frans
1.6k
88
1.1k
Sabre : Get session RQ
Jan 24 2019 9:35 PM
I am trying to create session using SessionCreateRQ soap service. where I have created object using HttpWebRequest https://sws3-crt.cert.sabre.com, and i have add the WSDL to service reference in my program:
String username =
"username"
;
String Pass =
"Pass"
;
String Ippc =
"iPseudo"
;
String ppc =
"pseudo"
;
String domain =
"DEFAULT"
;
DateTime dt = DateTime.UtcNow;
string
tstamp = dt.ToString(
"s"
) +
"Z"
;
sessionRQ.MessageHeader msgheader =
new
sessionRQ.MessageHeader();
msgheader.ConversationId =
"GetsessionRQ"
;
//Message Header message header from //
sessionRQ.From from =
new
sessionRQ.From();
sessionRQ.PartyId frompartid =
new
sessionRQ.PartyId();
sessionRQ.PartyId[] frompartidarr =
new
sessionRQ.PartyId[1];
frompartid.Value =
""
;
frompartidarr[0] = frompartid;
from.PartyId = frompartidarr;
msgheader.From = from;
//message Header, To //
sessionRQ.To to =
new
sessionRQ.To();
sessionRQ.PartyId topartid =
new
sessionRQ.PartyId();
sessionRQ.PartyId[] topartidarr =
new
sessionRQ.PartyId[1];
topartid.Value =
""
;
topartidarr[0] = topartid;
to.PartyId = topartidarr;
msgheader.To = to;
msgheader.CPAId = Ippc;
msgheader.Action =
"SessionCreateRQ"
;
sessionRQ.Service services =
new
sessionRQ.Service();
services.Value =
"SessionCreate"
;
msgheader.Service = services;
sessionRQ.MessageData msgData =
new
sessionRQ.MessageData();
msgData.MessageId =
"adong"
;
msgData.Timestamp = tstamp;
msgheader.MessageData = msgData;
sessionRQ.Security security =
new
sessionRQ.Security();
sessionRQ.SecurityUsernameToken securityusertoken =
new
sessionRQ.SecurityUsernameToken();
securityusertoken.Username = username;
securityusertoken.Password = Pass;
securityusertoken.Organization = Ippc;
securityusertoken.Domain = ppc;
security.UsernameToken = securityusertoken;
sessionRQ.SessionCreateRQ req =
new
sessionRQ.SessionCreateRQ();
sessionRQ.SessionCreateRQPOS pos =
new
sessionRQ.SessionCreateRQPOS();
sessionRQ.SessionCreateRQPOSSource source =
new
sessionRQ.SessionCreateRQPOSSource();
source.PseudoCityCode = Ippc;
pos.Source = source;
req.POS = pos;
sessionRQ.SessionCreateRQService servicesobj =
new
sessionRQ.SessionCreateRQService();
servicesobj.MessageHeaderValue = msgheader;
servicesobj.SecurityValue = security;
sessionRQ.SessionCreateRS resp =
new
sessionRQ.SessionCreateRS();
try
{
resp = servicesobj.SessionCreateRQ(req);
}
catch
(Exception ex)
{
System.Diagnostics.Debug.WriteLine(ex.ToString());
}
string
a, b;
a = msgheader.ConversationId;
b = security.BinarySecurityToken;
i got error like this : "The request was aborted: Could not create SSL/TLS secure channel". is there something wrong with my code?. and i have followed this code Consuming Sabre soap services using .net
Reply
Answers (
0
)
Usercontrol life cycle
the sql query is not working.im using service based database