UploadMedia
Uploads an image or video. Only JPG, PNG, GIF, WEBP, MP4 media types are supported.
ストアドプロシージャ固有の情報
Upload Media
Twitter に画像もしくはビデオをアップロードするプロシージャです。メディアID が返され、それを使って写真やビデオが添付されたツイートを作成することができます。アップロードされたメディアはアップロードから24時間で失効します。ビデオは15MB、30秒を超えることができません。
メディアファイルごとにMediaFilePath を設定します。例えば、メディアファイルをアップロードする設定は次のとおりです:
MediaFilePath - path/to/file1,path/to/file2
プロシージャの結果はメディアID のリストで、すべてのアップロードされたメディアごとにMediaId で取得できます。
Input
| Name | Type | Accepts Input Streams | Description |
| MediaFilePath | String | False | A comma-separated list of media file paths to upload. Takes precedence over 'Content' inputs. You can include up to 4 photos or 1 animated GIF or 1 video in a Tweet/DM with INSERT statements. |
| Content | String | True | The image or video data as an InputStream (JPG, PNG, GIF, WEBP or MP4). |
| FileName | String | False | The file name including extension to be used with the Content input. FileName is required for Content input. |
| ContentSize | String | False | The total size in bytes for the Content InputStream. Required when the Content input is used instead of MediaFilePath. |
| MediaCategory | String | False | A comma-separated list of media categories for each file path to upload or a single media category for a Content input. |
Result Set Columns
| Name | Type | Description |
| MediaId | String | The Ids of the media uploaded. |