简要描述:

  • 合同详情

请求URL:

  • /api/v2/contracts/:id

  • url请求参数说明
字段名 是否必填 描述
id true 合同的id,替换掉url的:id

请求方式:

  • GET

请求头:

请求参数:

返回示例:

正确时返回:


{
    "code": 0,
    "data": {
        "id": 15201,
        "category": "68092",
        "category_mapped": "采购合同",
        "payment_type": "68095",
        "payment_type_mapped": "支票",
        "status": "68102",
        "status_mapped": "意外终止",
        "is_editable": true,
        "organization_id": 10618,
        "title": "CRM集团版",
        "total_amount": "19800.0",
        "start_at": "2012-08-08",
        "end_at": "2012-09-09",
        "customer_signer": "自定义字段",
        "need_hidden_dispose": false,
        "revisit_remind_at": "",
        "received_payments_plan_count": 0,
        "received_payments_plan_amount": 0,
        "received_payments_amount": "0.0",
        "unreceived_amount": 19800,
        "unchecking_payments_amount": 19800,
        "checking_payments_amount": "0.0",
        "sn": "9989",
        "sign_date": "2015-08-08",
        "times": "2012-08-08 - 2012-09-09",
        "times_display": "2012-08-08 - 2012-09-09",
        "approve_status": "approved",
        "approve_status_i18n": "已通过",
        "approve_deny_type": 0,
        "file_asset_439992": [
            {
                "id": 310,
                "file_url": "https://cdn-files.ikcrm.com/attachments/files/35171740/2393022NHNfU.jpeg?imageslim",
                "origin_url": "https://cdn-files.ikcrm.com/attachments/files/35171740/2393022NHNfU.jpeg",
                "public_url": "https://cdn-files.ikcrm.com/attachments/files/35171740/2393022NHNfU.jpeg",
                "name": "2393022NHNfU.jpeg",
                "file_file_name": "2393022NHNfU.jpeg",
                "file_content_type": "image/jpeg",
                "file_file_size": 415,
                "attachmentable_id": 942,
                "attachmentable_type": "ContractAsset",
                "upload_time": "2024-11-18 10:15",
                "note": "",
                "sub_type": "file",
                "wx_media_id": null,
                "preview_url": "https://cdn-files.ikcrm.com/attachments/files/35/2393022NHNfU.jpeg?imageMogr/thumbnail/!250x250r/gravity/center/crop/!250x250/auto-orient",
                "download_url": "https://cdn-files.ikcrm.com/attachments/files/351/2393022NHNfU.jpeg?attname=2393022NHNfU.jpeg",
                "file_type": "image"
            }
        ],
        "all_attachments": [],
        "owned_department": {
            "id": 4411,
            "name": "总裁办"
        },
        "is_own": true,
        "is_has_policy_for_assist_user": true,
        "is_my_assist_entity": false,
        "product_assets_for_new_record": [],
        "our_signer": "自定义字段",
        "special_terms": "0",
        "created_at": "2018-05-25 17:22",
        "updated_at": "2018-05-25 17:22",
        "product_assets": "暂无产品",
        "attachments": "暂无附件",
        "before_user": {},
        "before_owned_department": {},
        "creator": {
            "id": 22267,
            "email": "test@qq.com",
            "created_at": "2018-05-24 14:43",
            "name": "test",
            "organization_id": 10618,
            "phone": "18321108963",
            "role_id": 0,
            "workflow_state": "organization_staff",
            "job": "",
            "tel": "",
            "avatar_url": "http://e.ikcrm.dev/assets/male.jpg",
            "department_name": "总裁办"
        },
        "user": {
            "id": 22267,
            "email": "test@qq.com",
            "created_at": "2018-05-24 14:43",
            "name": "test",
            "organization_id": 10618,
            "phone": "18321108963",
            "role_id": 0,
            "workflow_state": "organization_staff",
            "job": "",
            "tel": "",
            "avatar_url": "http://e.ikcrm.dev/assets/male.jpg",
            "department_name": "总裁办"
        },
        "opportunity": {},
        "customer": {
            "id": 321032,
            "name": "TEST5612",
            "name_pinyin": "TEST5612",
            "user_id": 22261,
            "user_name": "test01",
            "contacts": [],
            "company_name": "",
            "address": {
                "id": 440101,
                "tel": "19825685612",
                "tel_hidden_result": "19825685612",
                "phone": "",
                "phone_hidden_result": "",
                "qq": "",
                "email": "19825680001@test.com",
                "lng": 121.624653,
                "lat": 31.226515,
                "detail_address": "上海市浦东新区申江路5005弄星创广场C栋3楼5913室",
                "off_distance": -1,
                "url": "www.test5612.com",
                "gaode_staticmap": "http://restapi.amap.com/v3/staticmap?key=6336624d908c499cace3998613723a3a&location=121.624653%2C31.226515&markers=mid%2C%2CA%3A121.624653%2C31.226515&scale=2&size=524%2A180&zoom=16",
                "full_address": "中国 上海 上海市 浦东新区 上海市浦东新区申江路5005弄星创广场C栋3楼5913室"
            },
            "revisit_at": "2018-05-25T17:22:28.000+08:00",
            "is_own": true,
            "status": "68057",
            "status_mapped": "成交",
            "category": "68060",
            "category_mapped": "B(普通客户)",
            "qixinbao_id": "",
            "created_at": "2018-05-22 17:05",
            "updated_at": "2018-05-22 17:05",
            "creator": {
                "id": 22261,
                "email": "test011@qq.com",
                "created_at": "2018-05-22 15:20",
                "name": "test01",
                "organization_id": 10618,
                "phone": "19112345678",
                "role_id": 0,
                "workflow_state": "organization_staff",
                "job": "DD",
                "tel": "",
                "avatar_url": "http://e.ikcrm.dev/assets/male.jpg",
                "department_name": "总裁办"
            },
            "is_user_self": false,
            "approve_status": "approved",
            "approve_status_i18n": "已通过"
        },
        "can_approve": true,
        "step_can_approve": false,
        "step": 0,
        "notify_users": [],
        "can_revert_applying": false,
        "need_approve_step": 1,
        "attachments_count": 0,
        "file_attachments_count": 0,
        "is_user_self": true,
        "received_payment_plans": []
    }
}

错误时返回:

{
  "code": 100100,
  "message": "您没有权限查看该对象或该对象不存在。",
  "error": "active_record/record_not_found"
}

返回参数说明:

暂无

备注:

文档更新时间: 2025-04-29 14:18   作者:陈胜海