All Downloads are FREE. Search and download functionalities are using the official Maven repository.

.aws.api.0.8.589.source-code.scratch.clj Maven / Gradle / Ivy

(ns ^:skip-wiki scratch
  (:require
   [cognitect.aws.client.api :as aws]))

(def apigateway (aws/client {:api :apigateway}))

(sort (keys (aws/ops apigateway)))

(aws/doc apigateway :GetResources)

(aws/invoke apigateway {:op :GetRestApis})

(aws/invoke apigateway
            {:op :GetResources
             :request {:restApiId "40z4rhjol2" :embed ["methods"]}})

(meta *1)

(:import (clojure.lang ILookup)
         (java.util Map))

ILookup
(valAt [this k]
       (.valAt this k nil))

(valAt [this k default]
       (condp = k
         :region
         (some-> info :region-provider region/fetch)
         :credentials
         (some-> info :credentials-provider credentials/fetch)
         :endpoint
         (some-> info :endpoint-provider (endpoint/fetch (.valAt this :region)))
         (get info k default)))

Map
(entrySet [_] (.entrySet ^java.util.Map (->> (conj (keys info) :region :credentials :endpoint)
                                             (map (fn [k] [k nil]))
                                             (into (sorted-map)))))




© 2015 - 2025 Weber Informatics LLC | Privacy Policy