0

そのため、Issuu API を使用して、アップロードした最新の PDF に関するほとんどすべての情報を取得する URL を見つけることができました。問題は、その PDF をダウンロードするための URL を取得できるようにしたいということです。次の情報を使用して PDF をダウンロードする URL を特定するにはどうすればよいですか。

これは、issuu.documents.listアクションとその他のいくつかの引数を使用して、結果などを並べ替えたり制限したりした後の応答です (XML 応答と JSON 応答の両方を提供しました)。

XML レスポンス:

<rsp stat="ok">
    <result totalCount="257" startIndex="0" pageSize="1" more="true">
        <document
            username="thecrimsonwhite"
            name="09.14.11"
            documentId="110914053847-872eaa6e8f844601b0ef763d5332f7eb"
            title="The Crimson White"
            access="public"
            state="A"
            type="007000"
            orgDocType="pdf"
            orgDocName="09.14.11.pdf"
            downloadable="true"
            origin="singleupload"
            pro="F"
            rating="0.0"
            ratingsAllowed="true"
            commentCount="0"
            commentsAllowed="true"
            bookmarkCount="0"
            viewCount="71"
            pageCount="8"
            gfx="7"
            dcla="2|b|8|||810|1476|0|0"
            ls="1"
            ep="1315976400"
            publishDate="2011-09-14T05:00:00.000Z"
            description="The Crimson White is a student-created publication that aims to inform, entertain the University of Alabama and surrounding Tuscaloosa areas.">
            <tags>
                <tag value="news"/>
                <tag value="white"/>
                <tag value="sports"/>
                <tag value="lifestyles"/>
                <tag value="opinions"/>
                <tag value="crimson"/>
            </tags>
        </document>
    </result>
</rsp>

JSON レスポンス:

{"rsp":{"_content":{"result":{"totalCount":257,"startIndex":0,"pageSize":1,"more":true,"_content":[{"document":{"username":"thecrimsonwhite","name":"09.14.11","documentId":"110914053847-872eaa6e8f844601b0ef763d5332f7eb","title":"The Crimson White","access":"public","state":"A","type":"007000","orgDocType":"pdf","orgDocName":"09.14.11.pdf","downloadable":true,"origin":"singleupload","pro":"F","rating":0.00000e+0,"ratingsAllowed":true,"commentCount":0,"commentsAllowed":true,"bookmarkCount":0,"viewCount":71,"pageCount":8,"dcla":"2|b|8|||810|1476|0|0","ep":1315976400,"publishDate":"2011-09-14T05:00:00.000Z","description":"The Crimson White is a student-created publication that aims to inform, entertain the University of Alabama and surrounding Tuscaloosa areas.","tags":["news","white","sports","lifestyles","opinions","crimson"]}}]}},"stat":"ok"}}`

この特定のドキュメントのダウンロード ボタンの URL は次のとおりです。http://document.issuu.com/110914053847-872eaa6e8f844601b0ef763d5332f7eb/original.file?AWSAccessKeyId=AKIAJY7E3JMLFKPAGP7A&Expires=1316073684&Signature=r34xY8RUJYNxTL8X3SSedAWxDxk%3D

AWSAccessKeyIDおよびExpires属性とは何ですか? 署名が計算された MD5 合計であることは理解しています (ただし、 Signing Requestsのアルゴリズムと異なるかどうかはわかりません)。

これは、会社の新聞の最新の PDF 版を表示する開発中のアプリケーションにとって重要です。

4

1 に答える 1

1

AWSAccessKeyIdは、Amazon Web Service(AWS)アクセスキーです

ここでリクエストできる「APIキー」とは異なります。

したがって、同じAWSキーを使用すると、すべてのドキュメントで機能する可能性があります。

Expires属性はエポック日時です。URLにアクセスすると、現在または将来の日付/時刻をエポックでexpires属性値として送信する必要があります。ここでエポック形式で生成できます

署名は署名リクエストで与えられたものと同じです、あなたはそれをオンラインで生成するためのツールを知っていますか?

それが役立つかどうか教えてください。

-アルン・ジャイン

于 2011-09-29T07:12:02.497 に答える