docstr: Creating a workflow means pinging the wms server for a new id, or
  if providing an argument for an existing workflow, ensuring that
  it exists and receiving back the same identifier.
code: def create_workflow(self):
      """Creating a workflow means pinging the wms server for a new id, or
      if providing an argument for an existing workflow, ensuring that
      it exists and receiving back the same identifier.
      """
      import requests
  
      # Send the working directory to the server
      workdir = (
          os.getcwd()
          if not self.metadata.get("directory")
          else os.path.abspath(self.metadata["directory"])
      )
  
      # Prepare a request that has metadata about the job
      metadata = {
          "command": self.metadata.get("command"),
          "workdir": workdir,
      }
  
      response = requests.get(
          f"{self.address}/create_workflow",
          headers=self._headers,
          params=self.args,
          data=metadata,
      )
  
      # Extract the id from the response
      id = response.json()["id"]
  
      # Check the response, will exit on any error
      self.check_response(response, "/create_workflow")
  
      # Provide server parameters to the logger
      headers = (
          {"Content-Type": "application/json"}
          if self._headers is None
          else {**self._headers, **{"Content-Type": "application/json"}}
      )
  
      # Send the workflow name to the server
      response_change_workflow_name = requests.put(
          f"{self.address }/api/workflow/{id}",
          headers=headers,
          data=json.dumps(self.args),
      )
      # Check the response, will exit on any error
      self.check_response(
          response_change_workflow_name, f"/api/workflow/{id}"
      )
  
      # Provide server parameters to the logger
      self.server = {"url": self.address, "id": id}
  
imports: import logging
  import platform
  import time
  import datetime
  import sys
  import os
  import json
  import threading
  from functools import partial
  import inspect
  import textwrap
label_desc: Use image node_id 3 for calling the WMSLogger obj's underlying member method code with example usage: obj.create_workflow() without return types