(args)
| 829 | } |
| 830 | |
| 831 | function buildReadUrlContentBody(args) { |
| 832 | const parts = []; |
| 833 | if (args.url) parts.push(writeStringField(1, args.url)); |
| 834 | const doc = buildKnowledgeBaseItem({ |
| 835 | text: args.text || args.content || args.summary || '', |
| 836 | summary: args.summary || '', |
| 837 | url: args.url || args.resolved_url || '', |
| 838 | title: args.title || '', |
| 839 | }); |
| 840 | if (doc.length) parts.push(writeMessageField(2, doc)); |
| 841 | if (args.resolved_url) parts.push(writeStringField(3, args.resolved_url)); |
| 842 | if (args.latency_ms != null) parts.push(writeVarintField(4, Number(args.latency_ms) || 0)); |
| 843 | if (args.user_rejected) parts.push(writeBoolField(6, true)); |
| 844 | if (args.auto_run_decision != null) parts.push(writeVarintField(7, Number(args.auto_run_decision) || 0)); |
| 845 | return Buffer.concat(parts); |
| 846 | } |
| 847 | |
| 848 | const STEP_BODY_BUILDER = { |
| 849 | view_file: buildViewFileBody, |
nothing calls this directly
no test coverage detected