【问题标题】:Adding image to question item in the new google form rest api在新的谷歌表单rest api中将图像添加到问题项
【发布时间】:2022-07-07 05:21:02
【问题描述】:

是否可以在谷歌驱动器中使用图像?如果是,如何?我曾尝试使用https://drive.google.com/uc?id= + id,但失败了。

错误“:{ “代码”:400, "message": "从 source_uri 获取图片失败:https://drive.google.com/uc?id=xxxxxxxxxxxxxxxxxxxx", “状态”:“INVALID_ARGUMENT” }


图片 { “contentUri”:字符串, “altText”:字符串, “特性”: { 对象(媒体属性) }, “sourceUri”:字符串 }

【问题讨论】:

    标签: google-forms-api


    【解决方案1】:

    我用这个表格

    update = {
                "requests": [{
                {
                    "createItem": {
                        "item": {
                            "imageItem": {
                                "image": {
                                    "sourceUri": https://drive.google.com/uc...
                                    }
                                }   
                        },
                        "location": {
                            "index": 0
                        }
                    },
                },
                ]
            }
    
    service_form.forms().batchUpdate(
          formId=form_id, body=update).execute()
    

    文档https://developers.google.com/forms/api/reference/rest/v1/forms/batchUpdate

    【讨论】:

      【解决方案2】:

      您能否指导我如何集成 google form api...我只是想得到问题的答复....它一直在给我集成它的问题

      【讨论】:

        猜你喜欢
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 2018-03-26
        • 1970-01-01
        • 2019-06-23
        相关资源
        最近更新 更多