code: def post(method, hmc, uri, uri_parms, body, logon_required,
               wait_for_completion):
          
          assert wait_for_completion is True  # always synchronous
          check_required_fields(method, uri, body,
                                ['anticipated-frequency-seconds'])
          new_metrics_context = hmc.metrics_contexts.add(body)
          result = {
              'metrics-context-uri': new_metrics_context.uri,
              'metric-group-infos': new_metrics_context.get_metric_group_infos()
          }
          return result
docs: Operation: Create Metrics Context.