title: Calling a Google cloud function within Airflow DAG
body: <p>I have a google cloud function that is working, I am trying to call it from an Airflow DAG.</p>
  
  <p>what I have tried so far is to use the SimpleHttpOperator:</p>
  
  <pre><code>MY_TASK_NAME = SimpleHttpOperator(
          task_id= "MY_TASK_NAME",
          method='POST',
          http_conn_id='http_default',
          endpoint='https://us-central1-myprojectname.cloudfunctions.net/MyFunctionName',
          data=({"schema": schema, "table": table}),
          headers={"Content-Type": "application/json"},
          xcom_push=False
      )
  </code></pre>
  
  <p>but digging into the logs, it says it cannot find the resource:</p>
  
  <blockquote>
    <p>{base_task_runner.py:98} INFO - Subtask:   <p>The requested URL <code>/<a href="https://us-central1-myprojectname.cloudfunctions.net/MyFunctionName" rel="nofollow noreferrer">https://us-central1-myprojectname.cloudfunctions.net/MyFunctionName</a></code> was not found on this server.  That’s all we know.</p>
  </blockquote>
  
  <p>also I noticed that it actually posts to <a href="https://www.google.com/" rel="nofollow noreferrer">https://www.google.com/</a> + the url I gave:</p>
  
  <pre><code>Sending 'POST' to url: https://www.google.com/https://us-central1-myprojectname.cloudfunctions.net/MyFunctionName
  </code></pre>
  
  <p>what is the proper way to call the function ?
  Thanks</p>