0

私は助けが必要です 。

パラメータが url = ' https://www.google.com/calendar/feeds/email%40gmail.com/private/full ';を送信したときに、デスクトップ アプリケーションで Google カレンダーにイベントを作成したい。次に、このイベントを作成する場所にxmlを追加します

createXML := '<?xml version=''1.0'' encoding=''UTF-8''?>'#13#10 +
                  '<entry xmlns=''http://www.w3.org/2005/Atom'''#13#10 +
                  'xmlns:gd=''http://schemas.google.com/g/2005''>'#13#10 +
                  '<category scheme=''http://schemas.google.com/g/2005#kind'''#13#10 +
                  'term=''http://schemas.google.com/g/2005#event''></category>'#13#10 +
                  '<title type=''text''>' + title + '</title>'#13#10 +
                  '<content type=''text''>' + content + '</content>'#13#10 +
                  '<gd:transparency'#13#10 +
                  'value=''http://schemas.google.com/g/2005#event.opaque''>'#13#10 +
                  '</gd:transparency>'#13#10 +
                  '<gd:eventStatus'#13#10 +
                  'value=''http://schemas.google.com/g/2005#event.confirmed''>'#13#10 +
                  '</gd:eventStatus>'#13#10 +
                  '<gd:where valueString=''' + location + '''></gd:where>'#13#10 +
                  '<gd:when startTime=''' + EventStartTime + ''''#13#10 +
                  'endTime=''' + EventEndTime + '''></gd:when>'#13#10 +
                  '</entry>';

POST プロセスを実行すると、次のヘッダーが表示されます

HTTP/1.0 302 Moved Temporarily
Expires: Wed, 30 April 2014 17:37:17 GMT
Date: Wed, 30 April 2014 17:37:17 GMT
Set- Cookie: T=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx;
Expires = Tue, 13 -May- 2014 10:32:28 GMT;
SecureLocation : https://www.google.com:443/calendar/feeds/default/private/full?t=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Content- Type: text / html ; charset = UTF -8
Cache- Control: private , max -age = 0
X -Content -Type -Options : nosniff
X -Frame -Options : SAMEORIGIN
X -XSS -Protection : 1; mode = block
Server : GSE
Alternate -Protocol : 443: quic

マニュアルでは、Google は「GSessionID」という変数が必要だと記載していますが、私には表示されません
。この問題について教えてください。このパラメーターを取得するには、ClientLogin と OAuth 2.0 の 2 つの認証プロジェクトがありますか? どうもありがとう。

私たち Google 翻訳者

4

1 に答える 1

0

新しくロードされた gsessionID 条件を取得するために動作する必要があります post プロシージャを 2 回実現し、2 回目は例外で

  try
  idHTTP2.Post(URL,XML);
  except on E: EIdHTTPProtocolException do
    idHTTP2.Post(URL,XML);
  end;

御時間ありがとうございます。

于 2014-05-14T19:38:11.533 に答える