```/** * @NApiVersion 2.x * @NScriptType MapRedu...
# suitescript
m
Copy code
/**
 * @NApiVersion 2.x
 * @NScriptType MapReduceScript
 */
define(['N/service'], function(service) {
  function getInputData() {
    // This function is not relevant for this example
  }

  function map(context) {
    // This function is not relevant for this example
  }

  function reduce(context) {
    // This function is not relevant for this example
  }

  function summarize(summary) {
    // Retrieve the SOAP web services usage log
    var logs = service.getRequestLog({
      type: service.Type.WEB_SERVICE,
      operation: service.Operation.ALL
    });

    // Iterate through the log entries and log their information
    logs.forEach(function(log) {
      log.getFields().forEach(function(field) {
        log.getValue({ fieldId: field });
      });
    });
  }

  return {
    getInputData: getInputData,
    map: map,
    reduce: reduce,
    summarize: summarize
  };
});
b
very fancy fictional N/service module
🙌 2
a
This chatGPT is going to get people into troubles very very fast hahaha...
😂 2
💯 1
m
I kind of fired it from the hip here after it writing me some suitescript for HTTP POST requests that looked pretty good
s
Interesting use of MR there! Humans not quite out of business yet.
a
So I'm taking it this isn't a possible thing aside from running the native search
b
there are 2 saved search types, WSOperation and WSRecordProcessing that are related to soap
neither are supported by N/search
there is nothing on the analytics query side